Documenting MyClass#initialize

4 views
Skip to first unread message

dandean

unread,
Feb 6, 2009, 7:29:18 PM2/6/09
to PDoc
What is the correct format for documenting the "initialize" method for
classes?

Is it this?

/**
* MyClass#initialize(arg1, arg2, arg3)
* - arg1 (Integer): blah blah blah
* - arg2 (String): blah blah blah
* - arg3 (Boolean): blah blah blah
**/

I mostly ask because #initialize is sort of like a constructor, but
sort of not. Do we just treat it like a regular instance method?

Thanks!

Sébastien Gruhier

unread,
Feb 7, 2009, 2:22:35 AM2/7/09
to pd...@googlegroups.com
/**
*  new MyClass(arg1, arg2, arg3)
*  - options (Hash): override default options.
*   - arg1 (Integer): blah blah blah
*   - arg2 (Integer): blah blah blah
*   - arg3 (Integer): blah blah blah
*  
**/

You can have a look to http://addresschooser.mapeed.com, the site a and the documentation has been generated with pdoc.
HTH
Seb

-----------------------------------------------------------------------
http://xilinus.com    Web Application Development, Consulting, Training
http://mapeed.com     Markers fusion plugin for your online maps



Reply all
Reply to author
Forward
0 new messages