Interface OptionDescriptor
- All Superinterfaces:
org.refcodes.mixin.DescriptionAccessor,org.refcodes.mixin.EnvironmentVariableNameAccessor,org.refcodes.mixin.SystemPropertyNameAccessor,org.refcodes.mixin.TypeAccessor
- All Known Implementing Classes:
DiagnosticOptions.Configuration
OptionDescriptor interface describes enumerations representing
well known configuration options for subclasses of the Options class.
It allows an option to declare additional metadata such as a description, an expected value type, or custom names for the corresponding JVM system property and environment variable.
Optional methods defined by this interface provide default implementations
whose values are derived from the implementing enumeration's
Enum.name(). Implementing types only need to override these methods
when the default inference should be customized.
A subclass of the Options class typically defines an enumeration
implementing this interface and passes that enumeration to the (super)
Options(Options.Builder, Class) constructor. This enables
type safe access to known options and enriches diagnostic output such as
produced by the Options.toSchema() method.
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.refcodes.mixin.DescriptionAccessor
org.refcodes.mixin.DescriptionAccessor.DescriptionBuilder<B extends org.refcodes.mixin.DescriptionAccessor.DescriptionBuilder<B>>, org.refcodes.mixin.DescriptionAccessor.DescriptionMutator, org.refcodes.mixin.DescriptionAccessor.DescriptionPropertyNested classes/interfaces inherited from interface org.refcodes.mixin.EnvironmentVariableNameAccessor
org.refcodes.mixin.EnvironmentVariableNameAccessor.EnvironmentVariableNameBuilder<B extends org.refcodes.mixin.EnvironmentVariableNameAccessor.EnvironmentVariableNameBuilder<B>>, org.refcodes.mixin.EnvironmentVariableNameAccessor.EnvironmentVariableNameMutator, org.refcodes.mixin.EnvironmentVariableNameAccessor.EnvironmentVariableNamePropertyNested classes/interfaces inherited from interface org.refcodes.mixin.SystemPropertyNameAccessor
org.refcodes.mixin.SystemPropertyNameAccessor.SystemPropertyNameBuilder<B extends org.refcodes.mixin.SystemPropertyNameAccessor.SystemPropertyNameBuilder<B>>, org.refcodes.mixin.SystemPropertyNameAccessor.SystemPropertyNameMutator, org.refcodes.mixin.SystemPropertyNameAccessor.SystemPropertyNamePropertyNested classes/interfaces inherited from interface org.refcodes.mixin.TypeAccessor
org.refcodes.mixin.TypeAccessor.TypeBuilder<T,B extends org.refcodes.mixin.TypeAccessor.TypeBuilder<T, B>>, org.refcodes.mixin.TypeAccessor.TypeMutator<T>, org.refcodes.mixin.TypeAccessor.TypeProperty<T> -
Method Summary
Methods inherited from interface org.refcodes.mixin.DescriptionAccessor
getDescriptionMethods inherited from interface org.refcodes.mixin.TypeAccessor
getType
-
Method Details
-
getEnvironmentVariableName
Note: When returning null, the
Optionstype will infer the name from the implementing enumeration's name as ofEnvironmentVariable.toEnvironmentVariableName(String).- Specified by:
getEnvironmentVariableNamein interfaceorg.refcodes.mixin.EnvironmentVariableNameAccessor
-
getSystemPropertyName
Note: When returning null, the
Optionstype will infer the name from the implementing enumeration's name as ofSystemProperty.toSystemPropertyName(String).- Specified by:
getSystemPropertyNamein interfaceorg.refcodes.mixin.SystemPropertyNameAccessor
-