Klasse Options
java.lang.Object
org.apache.torque.generator.option.Options
A Store for all options.
-
Konstruktorübersicht
Konstruktoren -
Methodenübersicht
Modifizierer und TypMethodeBeschreibungvoid
addGlobalOptions
(Collection<Option> options) Adds several options with global scope.boolean
containsKey
(QualifiedName key) Checks if an option with the given key exists in any scope.getAllInHierarchy
(Namespace namespace) Returns all mappings which live in the given namespace.Returns a map containing all options in the global scope.getInHierarchy
(Namespace namespace) Returns all mappings which live in the given name space.Returns the value of the option which is closest in Hierarchy.keySet()
Returns all options in a set.void
setGlobalOption
(Option option) Sets an option with global scope.toString()
values()
Returns all options in a Collection.
-
Konstruktordetails
-
Options
public Options()
-
-
Methodendetails
-
setGlobalOption
Sets an option with global scope.- Parameter:
option
- the option to set, not null.- Löst aus:
NullPointerException
- if option is null.
-
addGlobalOptions
Adds several options with global scope.- Parameter:
options
- the option to add, not null, may not contain null.- Löst aus:
NullPointerException
- if options is null or contains null.
-
getInHierarchy
Returns the value of the option which is closest in Hierarchy. If more than one matching options (options with the matching name and in the name space or parent name space of the key) are found, the one which name space is closer to the given key's name space is chosen.- Parameter:
key
- the key for the option which value should be retrieved.- Gibt zurück:
- the value of the option (can be null), or null if no matching option exists.
-
getInHierarchy
Returns all mappings which live in the given name space. If one mapping hides another mapping, i.e. if one mapping is a more specialized version of another, the hidden mapping is NOT returned.- Parameter:
namespace
- the name space from which the returned options should be visible.- Gibt zurück:
- an Options object containing the matching options
-
getAllInHierarchy
Returns all mappings which live in the given namespace. If one mapping hides another mapping, i.e. if one mapping is a more specialized version of another, both mappings are present in the returned map.- Parameter:
namespace
- the name space from which the returned options should be visible.- Gibt zurück:
- an Options object containing the matching options
-
values
Returns all options in a Collection.- Gibt zurück:
- a Collection containing all options, not null. The collection is unmodifiable.
-
keySet
Returns all options in a set.- Gibt zurück:
- a Collection containing the qualified names of all options, not null.
-
getGlobalScope
Returns a map containing all options in the global scope. The key of the map is the key of the option, the value is the option itself.- Gibt zurück:
- a map containing the options in global scope, not null.
-
containsKey
Checks if an option with the given key exists in any scope.- Parameter:
key
- the key to check.- Gibt zurück:
- true if the key exists, false otherwise.
-
toString
-