
The "CoreDoc" tool has finally progressed far enough to generate useful API documentation for the JavaScript implementation of Echo3. This tool is capable of parsing Core.extend() blocks and properly marking static, virtual, and abstract methods. It additionally supports custom doc tags, which can be used to do things like specify the style properties and layout data properties that are supported by Echo components. The tool is not being written just to document the Echo API, but rather as a generic item for use with any project written using Core.js. It is still in its *very* early stages though. It currently is lacking some important capabilities, e.g., it's limited to parsing objects and methods (property support is not yet implemented). (now implemented)
In any case, the current JavaScript API docs may be found here:
http://echo.nextapp.com/content/echo3/doc/3.0/client-api/
(I didn't tell it to doc every single class in that run, but most of the important ones are there.)
I'll be posting the CoreDoc tool itself fairly soon, I just need to get an Ant build file and the usual "ReadMe.txt" and such in place (at the moment I'm running it straight out of Eclipse).
Best
--Tod
Example of custom tags
The following shows an example of custom tags (this is the doc comment for EchoApp.SplitPane):
/** * SplitPane component. * Splits a pane into two regions. A maximum of two components may be added as children. * * @sp {Number} orientation the orientation of the SplitPane, one of the following values: * <ul> * <li>ORIENTATION_HORIZONTAL_LEADING_TRAILING (the default)</li> * <li>ORIENTATION_HORIZONTAL_TRAILING_LEADING</li> * <li>ORIENTATION_HORIZONTAL_LEFT_RIGHT</li> * <li>ORIENTATION_HORIZONTAL_RIGHT_LEFT</li> * <li>ORIENTATION_VERTICAL_TOP_BOTTOM</li> * <li>ORIENTATION_VERTICAL_BOTTOM_TOP</li> * </ul> * @sp {Boolean} resizable flag indicating whether the pane separator can be moved * @sp {#Color} separatorColor the separator color * @sp {#Extent} separatorHeight the height of the separator (this property is used to determine the size * of the separator in vertical orientations * @sp {#FillImage} separatorHorizontalImage a FillImage used to paint the separator for horizontal orientations * @sp {#Extent} separatorPosition an extent specifying the position of the separator * @sp {#FillImage} separatorVerticalImage a FillImage used to paint the separator for vertical orientations * @sp {#Extent} separatorWidth the width of the separator (this property is used to determine the size * of the separator in horizontal orientations * * @ldp {#Alignment} alignment the alignment of the child component within its subpane * @ldp {#Color} background the background of the child component's subpane * @ldp {#FillImage} backrgoundImage the background image of the child component's subpane * @ldp {#Insets} insets the insets margin of the child component's subpane * @ldp {#Extent} maximumSize the maximum size of the child component's subpane * @ldp {#Extent} minimumSize the minimum size of the child component's subpane * @ldp {Number} overflow the layout behavior to use when the child component is larger than * its containing subpane, one of the following values: * <ul> * <li>OVERFLOW_AUTO (the default)</li> * <li>OVERFLOW_HIDDEN</li> * <li>OVERFLOW_SCROLL</li> * </ul> */The @sp and @ldp are custom tags. The "doc.xml" file, which contains instructions for how CoreDoc will parse your code, would then need to contain"custom-tag" elements like the following:
And the generated result: http://echo.nextapp.com/content/echo3/doc/3.0/client-api/Class.EchoApp.SplitPane.html
Field support is in!
Today was spent doing some major refactoring to the CoreDoc engine, and we now how support for fields as well as methods.