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. Focus Areas: BPEL | DITA | ebXML | IDtrust | OpenDocument | SAML | UBL | UDDI
OASIS sites: OASIS | Cover Pages | | AMQP | CGM Open | eGov | Emergency | IDtrust | LegalXML | Open CSA | OSLC | WS-I