Package org.apache.solr.schema
Class IndexSchema.DynamicReplacement
- java.lang.Object
-
- org.apache.solr.schema.IndexSchema.DynamicReplacement
-
- All Implemented Interfaces:
Comparable<IndexSchema.DynamicReplacement>
- Direct Known Subclasses:
IndexSchema.DynamicCopy
,IndexSchema.DynamicField
- Enclosing class:
- IndexSchema
public abstract static class IndexSchema.DynamicReplacement extends Object implements Comparable<IndexSchema.DynamicReplacement>
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected static class
IndexSchema.DynamicReplacement.DynamicPattern
-
Field Summary
Fields Modifier and Type Field Description protected IndexSchema.DynamicReplacement.DynamicPattern
pattern
-
Constructor Summary
Constructors Modifier Constructor Description protected
DynamicReplacement(String regex)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compareTo(IndexSchema.DynamicReplacement other)
Sort order is based on length of regex.String
getRegex()
Returns the regex used to create this instance's patternboolean
matches(String name)
-
-
-
Field Detail
-
pattern
protected IndexSchema.DynamicReplacement.DynamicPattern pattern
-
-
Constructor Detail
-
DynamicReplacement
protected DynamicReplacement(String regex)
-
-
Method Detail
-
matches
public boolean matches(String name)
-
compareTo
public int compareTo(IndexSchema.DynamicReplacement other)
Sort order is based on length of regex. Longest comes first.- Specified by:
compareTo
in interfaceComparable<IndexSchema.DynamicReplacement>
- Parameters:
other
- The object to compare to.- Returns:
- a negative integer, zero, or a positive integer as this object is less than, equal to, or greater than the specified object.
-
getRegex
public String getRegex()
Returns the regex used to create this instance's pattern
-
-