Moved out of MatchingTask to make it a standalone object that could be referenced (by scripts for example).
Modifier and Type | Class and Description |
---|---|
private static class | |
public class | PatternSet.NameEntry
inner class to hold a name on list. |
public class | PatternSet.PatternFileNameEntry
Adds encoding support to |
Modifier and Type | Field and Description |
---|---|
private List | |
private List | |
private List | |
private List |
Access | Constructor and Description |
---|---|
public |
Modifier and Type | Method and Description |
---|---|
public void | |
public void | addConfiguredPatternset(PatternSet
a configured patternset nested element. p)This is a patternset nested element. |
private PatternSet. | addPatternFileToList(List<PatternSet.
add a pattern file name entry to the given list |
private PatternSet. | |
public void | append(PatternSet
the other PatternSet instance. other, Project the current project. p)Adds the patterns of the other instance to this set. |
public Object | Returns: a clone of this patternset.Overrides org. |
public PatternSet. | Returns: a nested exclude element to be configured.add a name entry on the exclude list |
public PatternSet. | Returns: a nested excludesfile element to be configured.add a name entry on the exclude files list |
public PatternSet. | Returns: a nested include element to be configured.add a name entry on the include list |
public PatternSet. | Returns: a nested includesfile element to be configured.add a name entry on the include files list |
public String[] | Returns: the filtered excluded patterns.the current project. p)Returns the filtered include patterns. |
public String[] | Returns: the filtered included patterns.the current project. p)Returns the filtered include patterns. |
private PatternSet | |
public boolean | Returns: true if there are patterns.the current project. p)Helper for FileSet classes. |
private String[] | makeArray(List<PatternSet.
Convert a vector of NameEntry elements into an array of Strings. |
private void | |
private void | readPatterns(File patternfile, String encoding, List<PatternSet.
Reads path matching patterns from a file and adds them to the includes or excludes list (as appropriate). |
public void | setExcludes(String
the string containing the exclude patterns excludes)Appends |
public void | setExcludesfile(File
The file to fetch the exclude patterns from. excludesFile)Sets the name of the file containing the excludes patterns. |
public void | setIncludes(String
the string containing the include patterns includes)Appends |
public void | setIncludesfile(File
The file to fetch the include patterns from. includesFile)Sets the name of the file containing the includes patterns. |
public void | setRefid(Reference
the reference to another patternset. r)Overrides org. |
public String | Returns: a printable form of this object.Overrides org. |
excludeList | back to summary |
---|---|
private List<PatternSet. |
excludesFileList | back to summary |
---|---|
private List<PatternSet. |
includeList | back to summary |
---|---|
private List<PatternSet. |
includesFileList | back to summary |
---|---|
private List<PatternSet. |
PatternSet | back to summary |
---|---|
public PatternSet() Creates a new |
addConfiguredInvert | back to summary |
---|---|
public void addConfiguredInvert(PatternSet p) Add an inverted patternset.
|
addConfiguredPatternset | back to summary |
---|---|
public void addConfiguredPatternset(PatternSet p) This is a patternset nested element.
|
addPatternFileToList | back to summary |
---|---|
private PatternSet. add a pattern file name entry to the given list |
addPatternToList | back to summary |
---|---|
private PatternSet. add a name entry to the given list |
append | back to summary |
---|---|
public void append(PatternSet other, Project p) Adds the patterns of the other instance to this set.
|
clone | back to summary |
---|---|
public Object clone() Overrides org. Doc from java. Creates and returns a copy of this object. The precise meaning
of "copy" may depend on the class of the object. The general
intent is that, for any object will be true, and that the expression:x.clone() != x will bex.clone().getClass() == x.getClass() true , but these are not absolute requirements.
While it is typically the case that:
will bex.clone().equals(x) true , this is not an absolute requirement.
By convention, the returned object should be obtained by calling
By convention, the object returned by this method should be independent
of this object (which is being cloned). To achieve this independence,
it may be necessary to modify one or more fields of the object returned
by |
createExclude | back to summary |
---|---|
public PatternSet. add a name entry on the exclude list
|
createExcludesFile | back to summary |
---|---|
public PatternSet. add a name entry on the exclude files list
|
createInclude | back to summary |
---|---|
public PatternSet. add a name entry on the include list
|
createIncludesFile | back to summary |
---|---|
public PatternSet. add a name entry on the include files list
|
getExcludePatterns | back to summary |
---|---|
public String[] getExcludePatterns(Project p) Returns the filtered include patterns. |
getIncludePatterns | back to summary |
---|---|
public String[] getIncludePatterns(Project p) Returns the filtered include patterns. |
getRef | back to summary |
---|---|
private PatternSet getRef(Project p) Performs the check for circular references and returns the referenced PatternSet. |
hasPatterns | back to summary |
---|---|
public boolean hasPatterns(Project p) Helper for FileSet classes. Check if there are patterns defined.
|
makeArray | back to summary |
---|---|
private String[] makeArray(List<PatternSet. Convert a vector of NameEntry elements into an array of Strings. |
readFiles | back to summary |
---|---|
private void readFiles(Project p) Read includesfile ot excludesfile if not already done so. |
readPatterns | back to summary |
---|---|
private void readPatterns(File patternfile, String encoding, List<PatternSet. Reads path matching patterns from a file and adds them to the includes or excludes list (as appropriate). |
setExcludes | back to summary |
---|---|
public void setExcludes(String excludes) Appends
|
setExcludesfile | back to summary |
---|---|
public void setExcludesfile(File excludesFile) throws BuildException Sets the name of the file containing the excludes patterns.
|
setIncludes | back to summary |
---|---|
public void setIncludes(String includes) Appends
|
setIncludesfile | back to summary |
---|---|
public void setIncludesfile(File includesFile) throws BuildException Sets the name of the file containing the includes patterns.
|
setRefid | back to summary |
---|---|
public void setRefid(Reference r) throws BuildException Overrides org. Makes this instance in effect a reference to another PatternSet instance. You must not set another attribute or nest elements inside this element if you make it a reference.
|
toString | back to summary |
---|---|
public String toString() Overrides org. Doc from org. Basic DataType toString(). |
Access | Constructor and Description |
---|---|
private |
Modifier and Type | Method and Description |
---|---|
public String[] | getExcludePatterns(Project
the current project. p)Overrides org. |
public String[] | getIncludePatterns(Project
the current project. p)Overrides org. |
InvertedPatternSet | back to summary |
---|---|
private InvertedPatternSet(PatternSet p) |
getExcludePatterns | back to summary |
---|---|
public String[] getExcludePatterns(Project p) Overrides org. Doc from org. Returns the filtered include patterns. |
getIncludePatterns | back to summary |
---|---|
public String[] getIncludePatterns(Project p) Overrides org. Doc from org. Returns the filtered include patterns. |
Access | Constructor and Description |
---|---|
public |
Modifier and Type | Method and Description |
---|---|
public String | |
public String | |
public void | |
public void | |
public void | |
public void | |
public void | |
public String | Returns: a printable form of this object.Overrides java. |
private boolean |
ifCond | back to summary |
---|---|
private Object ifCond |
name | back to summary |
---|---|
private String name |
unlessCond | back to summary |
---|---|
private Object unlessCond |
NameEntry | back to summary |
---|---|
public NameEntry() |
evalName | back to summary |
---|---|
public String evalName(Project p) This validates the name - checks the if and unless properties. |
getName | back to summary |
---|---|
public String getName()
|
setIf | back to summary |
---|---|
public void setIf(Object cond) Sets the if attribute. This attribute and the "unless" attribute are used to validate the name, based on the existence of the property or the value of the evaluated property expression.
|
setIf | back to summary |
---|---|
public void setIf(String cond) Sets the if attribute. This attribute and the "unless" attribute are used to validate the name, based on the existence of the property or the value of the evaluated property expression.
|
setName | back to summary |
---|---|
public void setName(String name) Sets the name pattern.
|
setUnless | back to summary |
---|---|
public void setUnless(Object cond) Sets the unless attribute. This attribute and the "if" attribute are used to validate the name, based on the existence of the property or the value of the evaluated property expression.
|
setUnless | back to summary |
---|---|
public void setUnless(String cond) Sets the unless attribute. This attribute and the "if" attribute are used to validate the name, based on the existence of the property or the value of the evaluated property expression.
|
toString | back to summary |
---|---|
public String toString() Overrides java. Doc from java. Returns a string representation of the object. |
valid | back to summary |
---|---|
private boolean valid(Project p) |
NameEntry
.
Access | Constructor and Description |
---|---|
public |
Modifier and Type | Method and Description |
---|---|
public final String | Returns: the encoding nameEncoding to use when reading the file, defaults to the platform's default encoding. |
public final void | setEncoding(String
String encoding)Encoding to use when reading the file, defaults to the platform's default encoding. |
public String | toString()
Overrides org. |
encoding | back to summary |
---|---|
private String encoding |
PatternFileNameEntry | back to summary |
---|---|
public PatternFileNameEntry() |
getEncoding | back to summary |
---|---|
public final String getEncoding() Encoding to use when reading the file, defaults to the platform's default encoding.
|
setEncoding | back to summary |
---|---|
public final void setEncoding(String encoding) Encoding to use when reading the file, defaults to the platform's default encoding. For a list of possible values see https://docs.oracle.com/javase/8/docs/technotes/guides/intl/encoding.doc.html.
|
toString | back to summary |
---|---|
public String toString() Overrides org. Doc from java. Returns a string representation of the object.
|