Package io.goobi.viewer.controller.model
Class StringMatchConfiguration
java.lang.Object
io.goobi.viewer.controller.model.StringMatchConfiguration
A matcher read from a configuration node which matches strings based on certain criteria.
- Author:
- Florian Alpers
-
Constructor Summary
ConstructorsConstructorDescriptionStringMatchConfiguration(String includeRegex) StringMatchConfiguration(String includeRegex, String excludeRegex) StringMatchConfiguration(String includeRegex, String excludeRegex, List<String> allowedValues) StringMatchConfiguration(List<String> allowedValues) -
Method Summary
Modifier and TypeMethodDescriptionstatic StringMatchConfigurationfromConfig(org.apache.commons.configuration2.HierarchicalConfiguration<org.apache.commons.configuration2.tree.ImmutableNode> config) boolean
-
Constructor Details
-
StringMatchConfiguration
public StringMatchConfiguration(String includeRegex, String excludeRegex, List<String> allowedValues) - Parameters:
includeRegex- regex a string must match to be accepted; blank means no restrictionexcludeRegex- regex a string must not match to be accepted; blank means no restrictionallowedValues- explicit list of accepted values; empty means no restriction
-
StringMatchConfiguration
- Parameters:
allowedValues- explicit list of accepted values; no regex filtering applied
-
StringMatchConfiguration
- Parameters:
includeRegex- regex a string must match to be accepted; blank means no restrictionexcludeRegex- regex a string must not match to be accepted; blank means no restriction
-
StringMatchConfiguration
- Parameters:
includeRegex- regex a string must match to be accepted; blank means no restriction
-
-
Method Details
-
test
-
fromConfig
public static StringMatchConfiguration fromConfig(org.apache.commons.configuration2.HierarchicalConfiguration<org.apache.commons.configuration2.tree.ImmutableNode> config) - Parameters:
config- configuration node containing regex and allowed-values sub-elements- Returns:
StringMatchConfiguration
-