public class IndexerUtils extends Object
Modifier and Type | Field and Description |
---|---|
static String |
INDEXER_PROPERTIES |
static String |
INDEXER_XML |
Constructor and Description |
---|
IndexerUtils() |
Modifier and Type | Method and Description |
---|---|
static Indexer |
createDefaultIndexer() |
static String |
getAttribute(String coverageName,
String domainName,
Indexer indexer)
Look for the specified coverageName inside the provided Indexer and return the attributes of
the specified domain.
|
static Indexer.Coverages.Coverage |
getCoverage(Indexer indexer,
String name)
Return an indexer
Indexer.Coverages.Coverage object from the specified Indexer , referring to
the requested name. |
static DomainType |
getDomain(DomainType domain,
DomainsType refDomains) |
static String |
getParam(ParametersType params,
String parameterName)
Return the parameter string value of the specified parameter name from the provided
parameters element
|
static String |
getParameter(String parameterName,
File indexerFile)
Return the parameter string value of the specified parameter name from the indexer defined in
the specified file (if exists).
|
static String |
getParameter(String parameterName,
Indexer indexer)
Return the parameter string value of the specified parameter name from the provided indexer
|
static boolean |
getParameterAsBoolean(String parameterName,
Indexer indexer)
Return the parameter value (as a boolean) of the specified parameter name from the provider
indexer
|
static <T extends Enum> |
getParameterAsEnum(String parameterName,
Class<T> enumClass,
Indexer indexer)
Return the parameter value (as a boolean) of the specified parameter name from the provider
indexer
|
static SchemaType |
getSchema(Indexer indexer,
Indexer.Coverages.Coverage coverage)
Get a
SchemaType element for the specified Indexer.Coverages.Coverage . |
static Indexer |
initializeIndexer(ParametersType params,
File parent) |
static void |
parseAdditionalDomains(String attributes,
List<DomainType> domainList)
Parse additional domains
|
static String |
refineParameterValue(String parameterName,
String parameterValue)
Utility method which does special checks on specific parameters
|
static void |
setAttributes(DomainType domain,
String values)
Set the attributes of the specified domain, getting values from the value String In case the
value contains a ";" separator, add a different attribute for each element.
|
static void |
setParam(Indexer indexer,
String paramName,
String paramValue)
Set the given parameter on the given indexer
|
static void |
setParam(List<ParametersType.Parameter> parameters,
Properties props,
String propName)
Get the value of a property name from a properties object and set that value to a parameter
with the same name
|
static void |
setParam(List<ParametersType.Parameter> parameters,
String parameterName,
String parameterValue)
Set the parameter having the specified name with the specified value
|
static void |
setPropertyCollectors(Indexer indexer,
String propertyCollectors)
Build
Indexer.Collectors element by parsing the specified propertyCollectors, and put them on
the specified indexer object. |
public static final String INDEXER_XML
public static final String INDEXER_PROPERTIES
public static void setPropertyCollectors(Indexer indexer, String propertyCollectors)
Indexer.Collectors
element by parsing the specified propertyCollectors, and put them on
the specified indexer object.indexer
- propertyCollectors
- public static Indexer.Coverages.Coverage getCoverage(Indexer indexer, String name)
Indexer.Coverages.Coverage
object from the specified Indexer
, referring to
the requested name.indexer
- the main Indexer
instancename
- the name of the Indexer.Coverages.Coverage
element to be retrieved.Indexer.Coverages.Coverage
element for the specified name (if any).public static String refineParameterValue(String parameterName, String parameterValue)
parameterName
- parameterValue
- public static void setAttributes(DomainType domain, String values)
domain
- values
- public static void setParam(List<ParametersType.Parameter> parameters, String parameterName, String parameterValue)
parameters
- parameterName
- parameterValue
- public static void setParam(List<ParametersType.Parameter> parameters, Properties props, String propName)
parameters
- props
- propName
- public static boolean getParameterAsBoolean(String parameterName, Indexer indexer)
parameterName
- indexer
- public static <T extends Enum> T getParameterAsEnum(String parameterName, Class<T> enumClass, Indexer indexer)
parameterName
- indexer
- public static String getParam(ParametersType params, String parameterName)
params
- parameterName
- public static String getParameter(String parameterName, Indexer indexer)
parameterName
- indexer
- public static String getParameter(String parameterName, File indexerFile)
parameterName
- indexerFile
- public static void parseAdditionalDomains(String attributes, List<DomainType> domainList)
attributes
- domainList
- public static DomainType getDomain(DomainType domain, DomainsType refDomains)
public static String getAttribute(String coverageName, String domainName, Indexer indexer)
coverageName
- domainName
- indexer
- public static SchemaType getSchema(Indexer indexer, Indexer.Coverages.Coverage coverage)
SchemaType
element for the specified Indexer.Coverages.Coverage
. The Indexer
object will be used in case of an externally referenced schema.indexer
- the main Indexer
instancecoverage
- the Indexer.Coverages.Coverage
element with the Schema to be returned.public static Indexer createDefaultIndexer()
public static Indexer initializeIndexer(ParametersType params, File parent)
Copyright © 1996–2019 Geotools. All rights reserved.