bodewig 02/02/19 08:48:47
Modified: docs/manual/OptionalTasks replaceregexp.html
src/etc/testcases/taskdefs/optional replaceregexp.xml
src/main/org/apache/tools/ant/taskdefs/optional
ReplaceRegExp.java
src/main/org/apache/tools/ant/types RegularExpression.java
defaults.properties
Log:
<regularexpression> --> <regexp>
Revision Changes Path
1.7 +5 -5 jakarta-ant/docs/manual/OptionalTasks/replaceregexp.html
Index: replaceregexp.html
===================================================================
RCS file: /home/cvs/jakarta-ant/docs/manual/OptionalTasks/replaceregexp.html,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- replaceregexp.html 3 Feb 2002 22:09:09 -0000 1.6
+++ replaceregexp.html 19 Feb 2002 16:48:47 -0000 1.7
@@ -54,7 +54,7 @@
<tr>
<td valign="top">match</td>
<td valign="top">The regular expression pattern to match in the
file(s)</td>
- <td align="center">Yes, if no nested <regularexpression> is
used</td>
+ <td align="center">Yes, if no nested <regexp> is used</td>
</tr>
<tr>
<td valign="top">replace</td>
@@ -94,12 +94,12 @@
<h3>Parameters specified as nested elements</h3>
<p>This task supports a nested <a
href="../CoreTypes/fileset.html">FileSet</a>
element.</p>
-<p>This task supports a nested <i>RegularExpression</i> element to specify
+<p>This task supports a nested <i>Regexp</i> element to specify
the regular expression. You can use this element to refer to a previously
defined regular expression datatype instance.</p>
<blockquote>
- <regularexpression id="id" pattern="expression" /><br />
- <regularexpression refid="id" />
+ <regexp id="id" pattern="expression" /><br />
+ <regexp refid="id" />
</blockquote>
<p>This task supports a nested <i>Substitution</i> element to specify
the substitution pattern. You can use this element to refer to a
previously
@@ -112,7 +112,7 @@
<blockquote>
<pre>
<replaceregexp byline="true">
- <regularexpression expression="OldProperty=(.*)" />
+ <regexp expression="OldProperty=(.*)" />
<substitution expression="NewProperty=\1" />
<fileset dir=".">
<includes="*.properties" />
1.3 +1 -1
jakarta-ant/src/etc/testcases/taskdefs/optional/replaceregexp.xml
Index: replaceregexp.xml
===================================================================
RCS file:
/home/cvs/jakarta-ant/src/etc/testcases/taskdefs/optional/replaceregexp.xml,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- replaceregexp.xml 26 Oct 2001 09:36:40 -0000 1.2
+++ replaceregexp.xml 19 Feb 2002 16:48:47 -0000 1.3
@@ -10,7 +10,7 @@
<target name="testReplace" depends="setup">
<replaceregexp file="test.properties" byline="true">
- <regularexpression pattern="Old(.*)=(.*)" />
+ <regexp pattern="Old(.*)=(.*)" />
<substitution expression="NewProp=\1\2" />
</replaceregexp>
</target>
1.7 +3 -3
jakarta-ant/src/main/org/apache/tools/ant/taskdefs/optional/ReplaceRegExp.java
Index: ReplaceRegExp.java
===================================================================
RCS file:
/home/cvs/jakarta-ant/src/main/org/apache/tools/ant/taskdefs/optional/ReplaceRegExp.java,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- ReplaceRegExp.java 20 Jan 2002 20:45:57 -0000 1.6
+++ ReplaceRegExp.java 19 Feb 2002 16:48:47 -0000 1.7
@@ -1,7 +1,7 @@
/*
* The Apache Software License, Version 1.1
*
- * Copyright (c) 2001 The Apache Software Foundation. All rights
+ * Copyright (c) 2001-2002 The Apache Software Foundation. All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -107,7 +107,7 @@
* replace="pattern"
* flags="options"?
* byline="true|false"? >
- * regularexpression?
+ * regexp?
* substitution?
* fileset*
* </replaceregexp>
@@ -217,7 +217,7 @@
filesets.addElement(set);
}
- public RegularExpression createRegularExpression()
+ public RegularExpression createRegexp()
{
if (regex != null) {
throw new BuildException("Only one regular expression is
allowed.");
1.5 +4 -4
jakarta-ant/src/main/org/apache/tools/ant/types/RegularExpression.java
Index: RegularExpression.java
===================================================================
RCS file:
/home/cvs/jakarta-ant/src/main/org/apache/tools/ant/types/RegularExpression.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- RegularExpression.java 8 Jan 2002 22:21:59 -0000 1.4
+++ RegularExpression.java 19 Feb 2002 16:48:47 -0000 1.5
@@ -1,7 +1,7 @@
/*
* The Apache Software License, Version 1.1
*
- * Copyright (c) 2001 The Apache Software Foundation. All rights
+ * Copyright (c) 2001-2002 The Apache Software Foundation. All rights
* reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -83,7 +83,7 @@
* </pre>
*
* <pre>
- * <regularexpression [ [id="id"] pattern="expression" | refid="id" ]
+ * <regexp [ [id="id"] pattern="expression" | refid="id" ]
* />
* </pre>
*
@@ -96,7 +96,7 @@
*/
public class RegularExpression extends DataType
{
- public final static String DATA_TYPE_NAME = "regularexpression";
+ public final static String DATA_TYPE_NAME = "regexp";
// The regular expression factory
private final static RegexpFactory factory = new RegexpFactory();
@@ -151,7 +151,7 @@
Object o = ref.getReferencedObject(p);
if (!(o instanceof RegularExpression))
{
- String msg = ref.getRefId() + " doesn\'t denote a
regularexpression";
+ String msg = ref.getRefId() + " doesn\'t denote a
"+DATA_TYPE_NAME;
throw new BuildException(msg);
}
else
1.8 +1 -1
jakarta-ant/src/main/org/apache/tools/ant/types/defaults.properties
Index: defaults.properties
===================================================================
RCS file:
/home/cvs/jakarta-ant/src/main/org/apache/tools/ant/types/defaults.properties,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- defaults.properties 30 Nov 2001 11:33:26 -0000 1.7
+++ defaults.properties 19 Feb 2002 16:48:47 -0000 1.8
@@ -7,4 +7,4 @@
description=org.apache.tools.ant.types.Description
classfileset=org.apache.tools.ant.types.optional.depend.ClassfileSet
substitution=org.apache.tools.ant.types.Substitution
-regularexpression=org.apache.tools.ant.types.RegularExpression
+regexp=org.apache.tools.ant.types.RegularExpression
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>