Inclusion and Exclusion Patterns

Inclusion and Exclusion patterns can be configured for source folders. They define which files are considered by the Java builder and other Java tooling. This set of files consists of all files and folders where the path relative to the source folder matches an inclusion pattern but not an exclusion pattern.

By default, all files and folders contained in a source folder are included. By defining an inclusion pattern, the set of included resources will be limited to the resources matching the inclusion pattern. Using exclusion patterns, some of these resources can be excluded again.

Exclusion patterns are required when nesting source folders. The nested folder must be excluded from the outer source folder.

The patterns have the same format as ANT patterns:

Related concepts

Java builder
Classpath variables
Access rules

Related reference

Java Build Path properties