Eclipse IDE Configuration

Code Formatting

Eclipse 3.3 - and I guess also other Java IDEs - provides a Code Formatter option according the Java Convention by Sun. You may import the Eclipse Code Formatter Profile Java Conventions without tabs, which differs from Eclipse's build-in Java Convention Formatter Profile only by the Indentation Tab policy modified from Mixed to Spaces only.
In order to do it within Eclipse 3.3, download the Eclipse settings (java-conventions-without-tabs.xml) which are attached to the Coding Standards page. In Eclipse, click on Windows, Preferences, and then navigate to the Java/Code Style/Formatter section. Click on Import, and select the java-conventions-without-tabs.xml file. Click on OK to make these your active formatting settings.

Eclipse JRE configuration

The dcm4che projects are currently built against the Java 6 platform. To make sure you can build the projects and you are not using any Java 7 or higher features, make sure you configure a Java 6 JDK as follows:

  • Go to Window > Preferences... > Java > Installed JREs
  • Check the checkbox in front of the latest Java 6 JDK

Compiler Compliance

To set the correct Java compiler compliance, do the following:

  • In Window > Preferences... > Java > Compiler set the Compiler Compliance Level to 5.0
  • Make sure the 'Use default compliance settings' checkbox is checked

Compiler Errors and Warnings

Eclipse provides a lot of extra compiler checks that can provide very useful during development. In dcm4che we try to enable as much of them as possible. If you can, try to set the following compiler checks in Window > Preferences... > Java > Compiler > Errors/Warnings: