Diff for Java coding practices in the DITA-OT
Thu, 2011-01-27 12:55 by robander | Mon, 2011-01-31 10:15 by jelovirt | ||
---|---|---|---|
< previous diff | |||
Changes to Body | |||
Line 14 | Line 14 | ||
<li>Always use the specialized form to refer to elements. That is - do not write code that uses the "indexterm" element name; instead, code should depend upon the class attribute token, such as " topic/indexterm ".</li>
| <li>Always use the specialized form to refer to elements. That is - do not write code that uses the "indexterm" element name; instead, code should depend upon the class attribute token, such as " topic/indexterm ".</li>
| ||
<li>APIs should not be removed without a lot of thought and preparation.</li>
| <li>APIs should not be removed without a lot of thought and preparation.</li>
| ||
- | <li>All coding must use Java 1.5 or greater.</li>
| + | <li>All coding must use Java 1.5.</li>
|
<li>If you contribute to a Java file, you should add yourself to the Javadoc using @author tag. Note that this convention was added recently, so author information from the first few years of OT development is often missing.</li>
| <li>If you contribute to a Java file, you should add yourself to the Javadoc using @author tag. Note that this convention was added recently, so author information from the first few years of OT development is often missing.</li>
| ||
</ul>
| </ul>
| ||
Current revision:
Java coding practices in the DITA-OT
Java Coding practices in the DITA-OT
The core developers on the DITA Open Toolkit generally try to keep several coding practices and design patterns in mind when adding to the toolkit's Java code. If you are interested in digging around in the DITA Open Toolkit, or in contributing Java patches back to the core toolkit, you may want to keep these practices in mind.
Note that this page is currently under development.
- As with other coding modules, each Java file should contain a statement at the top indicating the copyright holder, and indicating the license. All code contributed to the toolkit must be compatible with the Apache 2.0 and CPL licenses.
- Always use the specialized form to refer to elements. That is - do not write code that uses the "indexterm" element name; instead, code should depend upon the class attribute token, such as " topic/indexterm ".
- APIs should not be removed without a lot of thought and preparation.
- All coding must use Java 1.5.
- If you contribute to a Java file, you should add yourself to the Javadoc using @author tag. Note that this convention was added recently, so author information from the first few years of OT development is often missing.