KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > idaremedia > antx > condition > ShortHandConditions


1 /**
2  * $Id: ShortHandConditions.java 180 2007-03-15 12:56:38Z ssmc $
3  * Copyright 2003-2004 iDare Media, Inc. All rights reserved.
4  *
5  * Originally written by iDare Media, Inc. for release into the public domain. This
6  * library, source form and binary form, is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Lesser General Public License as published by the
8  * Free Software Foundation; either version 2.1 of the License, or (at your option) any
9  * later version.<p>
10  *
11  * This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
12  * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
13  * See the GNU LGPL (GNU Lesser General Public License) for more details.<p>
14  *
15  * You should have received a copy of the GNU Lesser General Public License along with this
16  * library; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite
17  * 330, Boston, MA 02111-1307 USA. The LGPL can be found online at
18  * http://www.fsf.org/copyleft/lesser.html<p>
19  *
20  * This product has been influenced by several projects within the open-source community.
21  * The JWare developers wish to acknowledge the open-source community's support. For more
22  * information regarding the open-source products used within JWare, please visit the
23  * JWare website.
24  *----------------------------------------------------------------------------------------*
25  * WEBSITE- http://www.jware.info EMAIL- inquiries@jware.info
26  *----------------------------------------------------------------------------------------*
27  **/

28
29 package com.idaremedia.antx.condition;
30
31 import java.io.File JavaDoc;
32
33 import org.apache.tools.ant.types.Reference;
34 import org.apache.tools.ant.types.Path;
35
36 import com.idaremedia.antx.parameters.IgnoreCaseEnabled;
37 import com.idaremedia.antx.parameters.IgnoreWhitespaceEnabled;
38 import com.idaremedia.antx.parameters.MalformedCheckEnabled;
39 import com.idaremedia.antx.parameters.TrimEnabled;
40 import com.idaremedia.antx.parameters.FlexValueSupport;
41 import com.idaremedia.antx.parameters.IsA;
42
43 /**
44  * Collection of most common shorthand condition parameters supported by
45  * AntX rule tasks. The various "*Enabled" and the FlexValue support modify the
46  * primary shorthand condition.
47  *
48  * @since JWare/AntX 0.2
49  * @author ssmc, &copy;2003-2004 <a HREF="http://www.jware.info">iDare&nbsp;Media,&nbsp;Inc.</a>
50  * @version 0.5
51  * @.safety n/a
52  * @.group api,infra
53  **/

54
55 public interface ShortHandConditions
56     extends FlexValueSupport, IgnoreCaseEnabled, TrimEnabled,
57             IgnoreWhitespaceEnabled, MalformedCheckEnabled
58 {
59     /**
60      * Parameter shorthand for a single &lt;istrue&gt; condition.
61      **/

62     void setIsTrue(String JavaDoc name);
63
64     /**
65      * Parameter shorthand for a single &lt;isfalse&gt; condition.
66      **/

67     void setIsFalse(String JavaDoc name);
68
69
70
71     /**
72      * Parameter shorthand for a single &lt;isnotwhitespace&gt;
73      * condition.
74      **/

75     void setIsNotWhitespace(String JavaDoc name);
76
77     /**
78      * Parameter shorthand for a single &lt;isnumeric&gt; condition.
79      **/

80     void setIsNumeric(String JavaDoc name);
81
82     /**
83      * Parameter shorthand for a single &lt;isboolean&gt; condition.
84      **/

85     void setIsBoolean(String JavaDoc name);
86
87
88
89     /**
90      * Parameter shorthand for a single &lt;isset&gt; condition.
91      **/

92     void setIsSet(String JavaDoc name);
93
94     /**
95      * Parameter shorthand for a single &lt;issettrue&gt; condition.
96      **/

97     void setIsSetTrue(String JavaDoc name);
98
99     /**
100      * Modifier for a shorthand &lt;isboolean&gt; or &lt;issettrue&gt;
101      * condition.
102      **/

103     void setSynonyms(boolean allowAll);
104
105     /**
106      * Parameter shorthand for a single &lt;isnotset&gt; condition.
107      **/

108     void setIsNotSet(String JavaDoc name);
109
110     /**
111      * Source modifier for various shorthand &lt;isXXX&gt; conditions.
112      **/

113     void setIsA(IsA isa);
114
115
116
117     /**
118      * Parameter shorthand for a single &lt;isset isa="variable"&gt;
119      * condition.
120      **/

121     void setVarSet(String JavaDoc name);
122
123     /**
124      * Parameter shorthand for a single &lt;issettrue isa="variable"&gt;
125      * condition.
126      **/

127     void setVarSetTrue(String JavaDoc name);
128
129     /**
130      * Parameter shorthand for a single &lt;isnotset isa="variable"&gt;
131      * condition.
132      **/

133     void setVarNotSet(String JavaDoc name);
134
135
136
137     /**
138      * Parameter shorthand for a single &lt;allset&gt; condition.
139      **/

140     void setAllSet(String JavaDoc properties);
141
142     /**
143      * Parameter shorthand for a single &lt;anyset&gt; condition.
144      **/

145     void setAnySet(String JavaDoc properties);
146
147     /**
148      * Parameter shorthand for a single &lt;noneset&gt; condition.
149      **/

150     void setNoneSet(String JavaDoc properties);
151
152
153
154     /**
155      * Parameter shorthand for a single &lt;matches&gt; condition.
156      **/

157     void setMatches(String JavaDoc pattern);
158
159     /**
160      * Defines literal value used in a string matching condition.
161      **/

162     void setValue(String JavaDoc literal);
163
164
165
166     /**
167      * Parameter shorthand for a single &lt;available file="&#46;&#46;&#46;"&gt;
168      * condition.
169      **/

170     void setIsFile(File JavaDoc file);
171
172     /**
173      * Parameter shorthand for a single &lt;available file="&#46;&#46;&#46;" type="dir"&gt;
174      * condition.
175      **/

176     void setIsDirectory(File JavaDoc file);
177
178     /**
179      * Defines the path used to search for file or directory in an
180      * &lt;available&gt; shorthand condition.
181      **/

182     void setFilepath(Path filp);
183
184     /**
185      * Parameter shorthand for a single &lt;available classname="&#46;&#46;&#46;"&gt;
186      * condition.
187      **/

188     void setIsClass(String JavaDoc classname);
189
190     /**
191      * Parameter shorthand for a single &lt;available resource="&#46;&#46;&#46;"&gt;
192      * condition.
193      **/

194     void setIsResource(String JavaDoc name);
195
196     /**
197      * Defines the classpath used to search for a class or resource in
198      * an &lt;available&gt; shorthand condition.
199      **/

200     void setClasspath(Path clsp);
201
202     /**
203      * Defines the classpath reference used to search for a class or
204      * resource in an &lt;available&gt; shorthand condition.
205      **/

206     void setClasspathRef(Reference cpr);
207
208     /**
209      * Defines whether system classes included in classpath used to
210      * search for classes or resources in an &lt;available&gt; shorthand
211      * condition.
212      **/

213     void setSystemClasses(boolean included);
214
215
216
217     /**
218      * Parameter shorthand for a single &lt;os family="&#46;&#46;&#46;"&gt; condition.
219      **/

220     void setOSFamily(String JavaDoc family);
221
222     /**
223      * Parameter shorthand for a single AntX
224      * <span class="src">ifOS="&#46;&#46;&#46;"</span> condition.
225      * @since JWare/AntX 0.4
226      **/

227     void setOS(String JavaDoc selector);
228
229
230
231     /**
232      * Parameter shorthand for a single &lt;httpalive url="&#46;&#46;&#46;"&gt;
233      * condition.
234      * @since JWare/AntX 0.3
235      **/

236     void setHttpAlive(String JavaDoc url);
237 }
238
239 /* end-of-ShortHandConditions.java */
240
Popular Tags