|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.tools.ant.ProjectComponent org.apache.tools.ant.types.DataType org.apache.tools.ant.types.RegularExpression
public class RegularExpression
A regular expression datatype. Keeps an instance of the compiled expression for speed purposes. This compiled expression is lazily evaluated (it is compiled the first time it is needed). The syntax is the dependent on which regular expression type you are using. The system property "ant.regexp.regexpimpl" will be the classname of the implementation that will be used.
For jdk <= 1.3, there are two available implementations: org.apache.tools.ant.util.regexp.JakartaOroRegexp (the default) Based on the jakarta-oro package org.apache.tools.ant.util.regexp.JakartaRegexpRegexp Based on the jakarta-regexp package For jdk >= 1.4 an additional implementation is available: org.apache.tools.ant.util.regexp.Jdk14RegexpRegexp Based on the jdk 1.4 built in regular expression package.
<regexp [ [id="id"] pattern="expression" | refid="id" ] />
Perl5Compiler
,
RE
,
Pattern
,
Regexp
Field Summary | |
---|---|
static java.lang.String |
DATA_TYPE_NAME
Name of this data type |
Fields inherited from class org.apache.tools.ant.types.DataType |
---|
checked, ref |
Fields inherited from class org.apache.tools.ant.ProjectComponent |
---|
description, location, project |
Constructor Summary | |
---|---|
RegularExpression()
default constructor |
Method Summary | |
---|---|
java.lang.String |
getPattern(Project p)
Gets the pattern string for this RegularExpression in the given project. |
RegularExpression |
getRef(Project p)
Get the RegularExpression this reference refers to in the given project. |
Regexp |
getRegexp(Project p)
provides a reference to the Regexp contained in this |
void |
setPattern(java.lang.String pattern)
sets the regular expression pattern |
Methods inherited from class org.apache.tools.ant.types.DataType |
---|
checkAttributesAllowed, checkChildrenAllowed, circularReference, clone, dieOnCircularReference, dieOnCircularReference, dieOnCircularReference, getCheckedRef, getCheckedRef, getCheckedRef, getCheckedRef, getDataTypeName, getRefid, invokeCircularReferenceCheck, isChecked, isReference, noChildrenAllowed, setChecked, setRefid, tooManyAttributes, toString |
Methods inherited from class org.apache.tools.ant.ProjectComponent |
---|
getDescription, getLocation, getProject, log, log, setDescription, setLocation, setProject |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String DATA_TYPE_NAME
Constructor Detail |
---|
public RegularExpression()
Method Detail |
---|
public void setPattern(java.lang.String pattern)
pattern
- regular expression patternpublic java.lang.String getPattern(Project p)
p
- project
public Regexp getRegexp(Project p)
p
- project
public RegularExpression getRef(Project p)
p
- project
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |