Make WordPress Core

Opened 14 years ago

Closed 13 years ago

#15238 closed enhancement (fixed)

XML-RPC class should have better documentation

Reported by: koke's profile koke Owned by: westi's profile westi
Milestone: 3.2 Priority: normal
Severity: minor Version:
Component: XML-RPC Keywords: has-patch
Focuses: Cc:

Description

Right now, most of the comments on src:trunk/wp-includes/class.wp-xmlrpc-server.php are like this one:

	/**
	 * Retrieve page list.
	 *
	 * @since 2.2.0
	 *
	 * @param array $args Method parameters.
	 * @return unknown
	 */

At least they should detail more about the contents of $args and the values returned.

Attachments (2)

wp-xmlrpcdoc-15238-wip-1.patch (2.4 KB) - added by koke 14 years ago.
Commented some xmlrpc functions
wp-xmlrpcdoc-15238-wip-2.patch (2.7 KB) - added by koke 14 years ago.
More documentation for wp.getComments, wp.deleteComment, and wp.editComment

Download all attachments as: .zip

Change History (14)

@koke
14 years ago

Commented some xmlrpc functions

#1 @koke
14 years ago

  • Cc jbernal@… added

This should be an easy (although tedious) task. I've attached a patch commenting some of the functions. This way, the format and expected content of the documentation can be discussed before doing all the hard work

#3 @josephscott
14 years ago

  • Cc josephscott added

Some of this gets tricky, for instance if we allow for custom post statuses, trying to list the valid ones in the comments is going to be incomplete at best. Another challenge is that since most people interested in this API are external clients, they are unlikely to read the source code. In some cases they are forbidden from doing so.

Some of these have already been documented in the codex, and that might be a better place for these overall. The source code comments could link to the codex pages for reference.

#4 @nacin
14 years ago

  • Keywords gci needs-patch added
  • Milestone changed from Awaiting Review to Future Release

#5 @westi
14 years ago

  • Cc westi added

One of the reasons I want this in the code is so that the expected behaviour is documented with the implementation as this makes it much easier to review changes

#6 @koke
14 years ago

As an example, bbpress documentation in xmlrpc is quite good:
http://trac.bbpress.org/browser/trunk/xmlrpc.php#L497

@koke
14 years ago

More documentation for wp.getComments, wp.deleteComment, and wp.editComment

#7 @westi
14 years ago

  • Keywords gci removed
  • Milestone changed from Future Release to 3.2
  • Owner set to westi
  • Status changed from new to reviewing

Moving to 3.2 - documentation changes only

Removing GCI as the task was never done for GCI

#8 @jane
13 years ago

  • Keywords has-patch added; needs-patch removed

#9 @westi
13 years ago

(In [17646]) The beginings of better phpdoc for XMLRPC functions. See #15238 props koke.

#10 @westi
13 years ago

(In [17647]) More better phpdoc for XMLRPC functions. See #15238 props koke.

#11 @jane
13 years ago

  • Milestone changed from 3.2 to Future Release

This has as much as it can get for 3.2, are past freeze. Open new ticket(s) for additional documentation patches in next release.

#12 @nacin
13 years ago

  • Milestone changed from Future Release to 3.2
  • Resolution set to fixed
  • Status changed from reviewing to closed

New tickets for new patches.

Note: See TracTickets for help on using tickets.