The script_compiler_options parameter
defines how scripts are compiled into class files. You can pass options,
including any valid javac options to the compiler while the scripts
are compiled.
Parameter values
- Values
- nowarn
- Disable warning messages
- verbose
- Generate a verbose compiler status messages that include information
about each class loaded and each source file compiled
- deprecation
- Display source locations of where deprecated APIs are used (shorthand
for Xlint:deprecation)
- Xlint
- Makes available recommended warnings
- Xlint:warning
- Makes available or not available specified warnings, where warning can
be a combination of the following:
- all
- All of the warning options
- deprecation
- Display source locations of where deprecated APIs are used
- unchecked
- Give more detail for unchecked conversion warnings that are mandated
by the Java™ Language Specification
- fallthrough
- Check switch blocks for fall-through cases and
provide a warning message for any that are found
- path
- Warn about nonexistent path (class path, source path, and others)
directories
- serial
- Warn about missing serialVersionUID definitions
on serializable classes
- finally
- Warn about finally clauses that cannot end normally
For multiple warnings, separate each warning with
a comma.
- Example:
- In this example, the Xlint variable is used
in combination with the path option.
script_compiler_options=Xlint:path
- Default value
- nowarn
- Internal value
- nowarn
Restriction: The following options are already
used internally and must not be specified again with this parameter:
Example
In this example, no warnings are
generated by the complier.
script_compiler_options=nowarn