Modifier and Type | Class and Description |
---|---|
static class |
FilterSet.Filter
Individual filter component of filterset.
|
class |
FilterSet.FiltersFile
The filtersfile nested element.
|
static class |
FilterSet.OnMissing
EnumeratedAttribute to set behavior WRT missing filtersfiles:
"fail" (default), "warn", "ignore".
|
Modifier and Type | Field and Description |
---|---|
static String |
DEFAULT_TOKEN_END
The default token end string
|
static String |
DEFAULT_TOKEN_START
The default token start string
|
Modifier | Constructor and Description |
---|---|
|
FilterSet()
Default constructor.
|
protected |
FilterSet(FilterSet filterset)
Create a Filterset from another filterset.
|
Modifier and Type | Method and Description |
---|---|
void |
addConfiguredFilterSet(FilterSet filterSet)
Add a Filterset to this filter set.
|
void |
addConfiguredPropertySet(PropertySet propertySet)
Adds the properties provided by the specified PropertySet to this filterset.
|
void |
addFilter(FilterSet.Filter filter)
Add a new filter.
|
void |
addFilter(String token,
String value)
Add a new filter made from the given token and value.
|
Object |
clone()
Clone the filterset.
|
FilterSet.FiltersFile |
createFiltersfile()
Create a new FiltersFile.
|
String |
getBeginToken()
Get the begin token for this filterset.
|
String |
getEndToken()
Get the end token for this filterset.
|
Hashtable<String,String> |
getFilterHash()
Gets the filter hash of the FilterSet.
|
protected Vector<FilterSet.Filter> |
getFilters()
Get the filters in the filter set.
|
FilterSet.OnMissing |
getOnMissingFiltersFile()
Get the onMissingFiltersFile setting.
|
protected FilterSet |
getRef()
Get the referenced filter set.
|
boolean |
hasFilters()
Test to see if this filter set has filters.
|
boolean |
isRecurse()
Get whether recursive token expansion is enabled.
|
void |
readFiltersFromFile(File filtersFile)
Read the filters from the given file.
|
String |
replaceTokens(String line)
Does replacement on the given string with token matching.
|
void |
setBeginToken(String startOfToken)
Set the string used to id the beginning of a token.
|
void |
setEndToken(String endOfToken)
Set the string used to id the end of a token.
|
void |
setFiltersfile(File filtersFile)
Set the file containing the filters for this filterset.
|
void |
setOnMissingFiltersFile(FilterSet.OnMissing onMissingFiltersFile)
Set the behavior WRT missing filtersfiles.
|
void |
setRecurse(boolean recurse)
Set whether recursive token expansion is enabled.
|
checkAttributesAllowed, checkChildrenAllowed, circularReference, dieOnCircularReference, dieOnCircularReference, dieOnCircularReference, getCheckedRef, getCheckedRef, getCheckedRef, getCheckedRef, getDataTypeName, getRefid, invokeCircularReferenceCheck, isChecked, isReference, noChildrenAllowed, pushAndInvokeCircularReferenceCheck, setChecked, setRefid, tooManyAttributes, toString
getDescription, getLocation, getProject, log, log, setDescription, setLocation, setProject
public static final String DEFAULT_TOKEN_END
public static final String DEFAULT_TOKEN_START
public FilterSet()
protected FilterSet(FilterSet filterset)
filterset
- the filterset upon which this filterset will be based.public void addConfiguredFilterSet(FilterSet filterSet)
filterSet
- the filterset to be added to this filtersetpublic void addConfiguredPropertySet(PropertySet propertySet)
propertySet
- the propertyset to be added to this propertysetpublic void addFilter(FilterSet.Filter filter)
filter
- the filter to be added.public void addFilter(String token, String value)
token
- The token for the new filter.value
- The value for the new filter.public Object clone() throws BuildException
clone
in class DataType
BuildException
- if the clone cannot be performed.Cloneable
public FilterSet.FiltersFile createFiltersfile()
public String getBeginToken()
public String getEndToken()
public Hashtable<String,String> getFilterHash()
protected Vector<FilterSet.Filter> getFilters()
public FilterSet.OnMissing getOnMissingFiltersFile()
protected FilterSet getRef()
public boolean hasFilters()
public boolean isRecurse()
boolean
whether enabled.public void readFiltersFromFile(File filtersFile) throws BuildException
filtersFile
- the file from which filters are read.BuildException
- when the file cannot be read.public String replaceTokens(String line)
line
- The line in which to process embedded tokens.public void setBeginToken(String startOfToken)
startOfToken
- The new Begintoken value.public void setEndToken(String endOfToken)
endOfToken
- The new Endtoken value.public void setFiltersfile(File filtersFile) throws BuildException
filtersFile
- sets the filter file from which to read filters
for this filter set.BuildException
- if there is an error.public void setOnMissingFiltersFile(FilterSet.OnMissing onMissingFiltersFile)
onMissingFiltersFile
- the OnMissing describing the behavior.public void setRecurse(boolean recurse)
recurse
- boolean
whether to recurse.