public abstract class Configurator extends Object
AnnotatorServiceConfigurator
for an example of a Configurator extension.
Created by mssammon on 8/3/15.Constructor and Description |
---|
Configurator() |
Modifier and Type | Method and Description |
---|---|
protected Properties |
generateProperties(Property[] properties)
Creates the
Properties that is passed on to ResourceManager from a
list of default Property entries. |
ResourceManager |
getConfig(Map<String,String> nonDefaultValues)
get a Properties object with default values except for those provided in the
'nonDefaultValues' argument
|
ResourceManager |
getConfig(ResourceManager nonDefaultRm)
get a Properties object with default values except for those provided in the
'nonDefaultValues' argument
|
abstract ResourceManager |
getDefaultConfig()
get a ResourceManager object with the default key/value pairs for this configurator
|
static ResourceManager |
mergeProperties(List<ResourceManager> rmList)
merge a list of ResourceManager objects
|
static ResourceManager |
mergeProperties(ResourceManager first,
ResourceManager second)
combine two sets of properties to make a third Properties object; if both sets contain a
value for the same key, the value from the second ResourceManager is selected.
|
public static ResourceManager mergeProperties(ResourceManager first, ResourceManager second)
first
- ResourceManager with first set of propertiessecond
- ResourceManager with second set of propertiespublic static ResourceManager mergeProperties(List<ResourceManager> rmList)
rmList
- list of ResourceManager objectspublic abstract ResourceManager getDefaultConfig()
protected Properties generateProperties(Property[] properties)
Properties
that is passed on to ResourceManager
from a
list of default Property
entries.properties
- The list default Property
entriesProperties
containing the defined propertiespublic ResourceManager getConfig(Map<String,String> nonDefaultValues)
nonDefaultValues
- specify ONLY those values you wish to overrideResourceManager
containing the defined propertiespublic ResourceManager getConfig(ResourceManager nonDefaultRm)
nonDefaultRm
- specify ONLY those values you wish to overrideResourceManager
containing the defined propertiesCopyright © 2017. All rights reserved.