Standard Web Project Properties Dialog Box: Sources

See Also

You open the Standard Web Project Properties dialog box by right-clicking any  and choosing Properties.

The Sources page lets you set the locations for commonly-used directories within the project folder of a Java web project, such as the WEB-INF and Web Pages folders. It also allows you to specify the project's source package and test package folders, set the JDK version that corresponds to the project's source/binary format, include or exclude classes to be compiled with the project, and set the default project character encoding.

Project Folders

Source and Test Package Folders:

A pane is provided for both source and test package folders, listing the location of package folders, and the label used for them in the Project Properties window. You can use the Test Package Folders pane to specify the folder that the IDE uses when creating JUnit tests. By default, when you create a project the IDE creates a test packages folder called test with the label Test Packages. Use the buttons to the right of the panes to add, remove, and change the order of the package folders.

To create JUnit tests with the IDE, a project must include a test package folder. If the test packages folder for your project is missing or unavailable, you can create a new folder in your project and then use this pane to designate the new folder as the Test Package folder.

You can have multiple source roots in a standard project, with the following exceptions:

Source/Binary Format

You can use the Source/Binary Format combo box to set the lowest Java platform version with which the generated Java code should be compatible. This setting corresponds to the javac -source option. Setting the source/binary format helps prevent you from using Java language constructs that are not available in the platform version to which you want to deploy. However, setting the source/binary format does not ensure that the platform APIs are used compatibly with that platform version. To make sure that your application is fully compatible with an earlier Java platform version, you need to switch to the Libraries tab and set the Java Platform setting to the minimum version on which you plan to deploy.

Project Character Encoding

The project character encoding determines how the IDE interprets characters in your source files. The IDE displays and saves any new files you create using the encoding set by the project in which they reside. The default character encoding used with projects is UTF-8. Use the Encoding drop-down to change the character encoding used with the project.

For more information on Project encoding, see About Project Encodings.

See Also
About Standard Projects
About Free-Form Projects
Creating a JUnit Test
Standard Web Project Properties Dialog Box:
         Frameworks
         Libraries
         Compiling
         Packaging
         Documenting
         Run
         Web Services
         Web Service Clients

Legal Notices