Interface Option
- All Superinterfaces:
DescriptionAccessor, org.refcodes.ontology.EnumTerm, EnvironmentVariableNameAccessor, NameAccessor, Setting, SystemPropertyNameAccessor, org.refcodes.ontology.Term, TypeAccessor, org.refcodes.ontology.UnsafeConcept, org.refcodes.ontology.UnsafeTaxon
- All Known Implementing Classes:
DiagnosticOption
Option type extends the Setting type and describes
enumerations representing well known and normalized (hierarchical)
configuration options for subclasses of the Options container.
Beyond looking up Option elements within the Options
taxonomy, Option elements can also resolve from Java's system
properties and the system's environment variables.
Environment variable names as well as system property names are derived from
Enum.name() and can by overridden by overwriting the
getEnvironmentVariableName() and getSystemPropertyName()
methods.
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 DescriptionAccessor
DescriptionAccessor.DescriptionBuilder<B>, DescriptionAccessor.DescriptionMutator, DescriptionAccessor.DescriptionPropertyNested classes/interfaces inherited from interface EnvironmentVariableNameAccessor
EnvironmentVariableNameAccessor.EnvironmentVariableNameBuilder<B>, EnvironmentVariableNameAccessor.EnvironmentVariableNameMutator, EnvironmentVariableNameAccessor.EnvironmentVariableNamePropertyNested classes/interfaces inherited from interface NameAccessor
NameAccessor.NameBuilder<B>, NameAccessor.NameMutator, NameAccessor.NamePropertyNested classes/interfaces inherited from interface SystemPropertyNameAccessor
SystemPropertyNameAccessor.SystemPropertyNameBuilder<B>, SystemPropertyNameAccessor.SystemPropertyNameMutator, SystemPropertyNameAccessor.SystemPropertyNamePropertyNested classes/interfaces inherited from interface TypeAccessor
TypeAccessor.TypeBuilder<T,B>, TypeAccessor.TypeMutator<T>, TypeAccessor.TypeProperty<T> -
Method Summary
Methods inherited from interface DescriptionAccessor
getDescriptionMethods inherited from interface TypeAccessor
getTypeMethods inherited from interface org.refcodes.ontology.UnsafeConcept
get, getOr, putMethods inherited from interface org.refcodes.ontology.UnsafeTaxon
getName, name
-
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 interfaceEnvironmentVariableNameAccessor
-
getSystemPropertyName
Note: When returning null, the
Optionstype will infer the name from the implementing enumeration's name as ofSystemProperty.toSystemPropertyName(String).- Specified by:
getSystemPropertyNamein interfaceSystemPropertyNameAccessor
-