|
⇤ ← Revision 1 as of 2005-02-11 02:10:20
Size: 1403
Comment:
|
Size: 1431
Comment:
|
| Deletions are marked like this. | Additions are marked like this. |
| Line 6: | Line 6: |
| === Example === | === Example (adapted from Sun document) === |
Coding Standards for Java Code in Jython
When in doubt follow the Sun Java standards:
http://java.sun.com/docs/codeconv/
Example (adapted from Sun document)
package org.jython.blah;
import org.jython.blah.BlahBlah;
/**
* Class description goes here.
* @author Firstname Lastname
*/
public class Blah extends SomeClass {
/* A class implementation comment can go here. */
/** classVar1 documentation comment */
public static int classVar1;
/**
* classVar2 documentation comment that happens to be
* more than one line long
*/
private static Object classVar2;
/** instanceVar1 documentation comment */
public Object instanceVar1;
/** instanceVar2 documentation comment */
protected int instanceVar2;
/** instanceVar3 documentation comment */
private Object[] instanceVar3;
/**
* ...constructor Blah documentation comment...
*/
public Blah() {
// ...implementation goes here...
}
/**
* ...method doSomething documentation comment...
*/
public void doSomething() {
// ...implementation goes here...
}
/**
* ...method doSomethingElse documentation comment...
* @param someParam description
*/
public void doSomethingElse(Object someParam) {
// ...implementation goes here...
}
}