You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ant.apache.org by um...@apache.org on 2002/05/17 20:34:02 UTC
cvs commit: jakarta-ant/docs/manual/CoreTypes filterchain.html
umagesh 02/05/17 11:34:02
Modified: docs/manual/CoreTypes Tag: ANT_15_BRANCH filterchain.html
Log:
Documentation for a few filter readers added in.
Revision Changes Path
No revision
No revision
1.1.2.1 +145 -0 jakarta-ant/docs/manual/CoreTypes/filterchain.html
Index: filterchain.html
===================================================================
RCS file: /home/cvs/jakarta-ant/docs/manual/CoreTypes/filterchain.html,v
retrieving revision 1.1
retrieving revision 1.1.2.1
diff -u -r1.1 -r1.1.2.1
--- filterchain.html 7 Mar 2002 03:09:59 -0000 1.1
+++ filterchain.html 17 May 2002 18:34:02 -0000 1.1.2.1
@@ -239,6 +239,108 @@
</loadfile>
</PRE></BLOCKQUOTE>
+<H3><a name="linecontains">LineContains</a></H3>
+
+This filter includes only those lines that contain all the user-specified
+strings.
+
+<TABLE cellSpacing=0 cellPadding=2 border=1>
+ <TR>
+ <TD vAlign=top><B>Parameter Type</B></TD>
+ <TD vAlign=top><B>Parameter Value</B></TD>
+ <TD vAlign=top align="center"><B>Required</B></TD>
+ </TR>
+ <TR>
+ <TD vAlign=top>contains</TD>
+ <TD vAlign=top align="center">Substring to be searched for.</TD>
+ <TD vAlign=top align="center">Yes</TD>
+ </TR>
+</TABLE>
+<P>
+<H4>Example:</H4>
+
+This will include only those lines that contain <code>foo</code> and
+<code>bar</code>.
+<BLOCKQUOTE><PRE>
+<filterreader classname="org.apache.tools.ant.filters.LineContains">
+ <param type="contains" value="foo"/>
+ <param type="contains" value="bar"/>
+</filterreader>
+</PRE></BLOCKQUOTE>
+
+Convenience method:
+<BLOCKQUOTE><PRE>
+<linecontains>
+ <contains value="foo">
+ <contains value="bar">
+</linecontains>
+</PRE></BLOCKQUOTE>
+
+<H3><a name="linecontainsregexp">LineContainsRegExp</a></H3>
+
+Filter which includes only those lines that contain the user-specified
+regular expression matching strings.
+
+<TABLE cellSpacing=0 cellPadding=2 border=1>
+ <TR>
+ <TD vAlign=top><B>Parameter Type</B></TD>
+ <TD vAlign=top><B>Parameter Value</B></TD>
+ <TD vAlign=top align="center"><B>Required</B></TD>
+ </TR>
+ <TR>
+ <TD vAlign=top>regexp</TD>
+ <TD vAlign=top align="center">Pattern of the substring to be searched for.</TD>
+ <TD vAlign=top align="center">Yes</TD>
+ </TR>
+</TABLE>
+<P>
+<H4>Example:</H4>
+
+This will fetch all those lines that contain the pattern <code>foo</code>
+<BLOCKQUOTE><PRE>
+<filterreader classname="org.apache.tools.ant.filters.LineContainsRegExp">
+ <param type="regexp" value="foo*"/>
+</filterreader>
+</PRE></BLOCKQUOTE>
+
+Convenience method:
+<BLOCKQUOTE><PRE>
+<linecontainsregexp>
+ <regexp pattern="foo*">
+</linecontainsregexp>
+</PRE></BLOCKQUOTE>
+
+<H3><a name="prefixlines">PrefixLines</a></H3>
+
+Attaches a prefix to every line.
+
+<TABLE cellSpacing=0 cellPadding=2 border=1>
+ <TR>
+ <TD vAlign=top><B>Parameter Name</B></TD>
+ <TD vAlign=top><B>Parameter Value</B></TD>
+ <TD vAlign=top align="center"><B>Required</B></TD>
+ </TR>
+ <TR>
+ <TD vAlign=top>prefix</TD>
+ <TD vAlign=top align="center">Prefix to be attached to lines.</TD>
+ <TD vAlign=top align="center">Yes</TD>
+ </TR>
+</TABLE>
+<P>
+<H4>Example:</H4>
+
+This will attach the prefix <code>foo</code> to all lines.
+<BLOCKQUOTE><PRE>
+<filterreader classname="org.apache.tools.ant.filters.PrefixLines">
+ <param name="prefix" value="Foo"/>
+</filterreader>
+</PRE></BLOCKQUOTE>
+
+Convenience method:
+<BLOCKQUOTE><PRE>
+<prefixlines prefix="Foo"/>
+</PRE></BLOCKQUOTE>
+
<H3><a name="replacetokens">ReplaceTokens</a></H3>
This filter reader replaces all strings that are
@@ -376,6 +478,49 @@
</filterreader>
</filterchain>
</loadfile>
+</PRE></BLOCKQUOTE>
+
+<H3><a name="striplinecomments">StripLineComments</a></H3>
+
+This filter removes all those lines that begin with strings
+that represent comments as specified by the user.
+
+<TABLE cellSpacing=0 cellPadding=2 border=1>
+ <TR>
+ <TD vAlign=top><B>Parameter Type</B></TD>
+ <TD vAlign=top><B>Parameter Value</B></TD>
+ <TD vAlign=top align="center"><B>Required</B></TD>
+ </TR>
+ <TR>
+ <TD vAlign=top>comment</TD>
+ <TD vAlign=top align="center">Strings that identify a line as a comment
+ when they appear at the start of the line.</TD>
+ <TD vAlign=top align="center">Yes</TD>
+ </TR>
+</TABLE>
+<P>
+<H4>Examples:</H4>
+
+This removes all lines that begin with #, --, REM, rem and //
+<BLOCKQUOTE><PRE>
+<filterreader classname="org.apache.tools.ant.filters.StripLineComments">
+ <param type="comment" value="#"/>
+ <param type="comment" value="--"/>
+ <param type="comment" value="REM "/>
+ <param type="comment" value="rem "/>
+ <param type="comment" value="//"/>
+</filterreader>
+</PRE></BLOCKQUOTE>
+
+Convenience method:
+<BLOCKQUOTE><PRE>
+<striplinecomments>
+ <comment value="#"/>
+ <comment value="--"/>
+ <comment value="REM "/>
+ <comment value="rem "/>
+ <comment value="//"/>
+</striplinecomments>
</PRE></BLOCKQUOTE>
<H3><a name="tabstospaces">TabsToSpaces</a></H3>
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>