KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > enhydra > shark > api > common > ProcessMgrIteratorExpressionBuilder


1 /* ProcessMgrIteratorExpressionBuilder.java */
2
3 package org.enhydra.shark.api.common;
4
5 import java.io.Serializable JavaDoc;
6
7 /**
8  * ProcessMgrIteratorExpressionBuilder
9  * <p>
10  * All methods are returng the object itself to allow stacking method
11  * calls on the same object.
12  *
13  * @author V.Puskas
14  * @version 0.3
15  */

16 public interface ProcessMgrIteratorExpressionBuilder extends
17                                                     ExpressionBuilder,
18                                                     Serializable JavaDoc {
19    /**
20     * Appends <b>AND </b> operator to expression
21     *
22     * @return itself
23     */

24    public ProcessMgrIteratorExpressionBuilder and();
25
26    /**
27     * Appends <b>OR </b> operator to expression
28     *
29     * @return itself
30     */

31    public ProcessMgrIteratorExpressionBuilder or();
32
33    /**
34     * Appends <b>NOT </b> operator to expression
35     *
36     * @return itself
37     */

38    public ProcessMgrIteratorExpressionBuilder not();
39
40    /**
41     * Appends condition "pakcage id == value of exp"
42     *
43     * @param exp
44     * @return itself
45     */

46    public ProcessMgrIteratorExpressionBuilder addPackageIdEquals(String JavaDoc exp);
47
48    /**
49     * Appends condition "process definition id == value of exp"
50     *
51     * @param exp
52     * @return itself
53     */

54    public ProcessMgrIteratorExpressionBuilder addProcessDefIdEquals(String JavaDoc exp);
55
56    /**
57     * Appends condition "process manager name == value of exp"
58     *
59     * @param exp
60     * @return itself
61     */

62    public ProcessMgrIteratorExpressionBuilder addNameEquals(String JavaDoc exp);
63
64    /**
65     * Appends condition "process manager version == value of exp"
66     *
67     * @param exp
68     * @return itself
69     */

70    public ProcessMgrIteratorExpressionBuilder addVersionEquals(String JavaDoc exp);
71
72    /**
73     * Appends condition "process manager created time == arg"
74     *
75     * @param arg
76     * @return itself
77     */

78    public ProcessMgrIteratorExpressionBuilder addCreatedTimeEquals(long arg);
79
80    /**
81     * Appends condition "process manager created time < arg"
82     *
83     * @param arg
84     * @return itself
85     */

86    public ProcessMgrIteratorExpressionBuilder addCreatedTimeBefore(long arg);
87
88    /**
89     * Appends condition "process manager created time > arg"
90     *
91     * @param arg
92     * @return itself
93     */

94    public ProcessMgrIteratorExpressionBuilder addCreatedTimeAfter(long arg);
95
96    /**
97     * Appends condition "process manager enabled"
98     *
99     * @return itself
100     */

101    public ProcessMgrIteratorExpressionBuilder addIsEnabled();
102
103    /**
104     * Appends arbitrary condition
105     * <p>
106     * Here you may specify any script compatible expression, but <b>beware
107     * complete expression will be evaluated inside Java VM</b>, not on DB.
108     *
109     * @param exp
110     * @return itself
111     */

112    public ProcessMgrIteratorExpressionBuilder addExpression(String JavaDoc exp);
113
114    /**
115     * Appends condition contained inside other
116     * <tt>ProcessMgrIteratorExpressionBuilder</tt>. This allows user
117     * to build more complicated expressions, because eb condition is
118     * nested into parenthesis.
119     *
120     * @param eb
121     * @return itself
122     */

123    public ProcessMgrIteratorExpressionBuilder addExpression(ProcessMgrIteratorExpressionBuilder eb);
124
125    /**
126     * Methods starting with <tt>setOrderBy</tt> obviously don't affect
127     * actual expression (nor its evaluation), rather they affect sorting
128     * of the result.
129     * <p>
130     * This method sets ordering by packageId value.
131     *
132     * @param ascending
133     * @return itself
134     */

135    public ProcessMgrIteratorExpressionBuilder setOrderByPackageId(boolean ascending);
136
137    /**
138     * Methods starting with <tt>setOrderBy</tt> obviously don't affect
139     * actual expression (nor its evaluation), rather they affect sorting
140     * of the result.
141     * <p>
142     * This method sets ordering by processDefinitionId value.
143     *
144     * @param ascending
145     * @return itself
146     */

147    public ProcessMgrIteratorExpressionBuilder setOrderByProcessDefId(boolean ascending);
148
149    /**
150     * Methods starting with <tt>setOrderBy</tt> obviously don't affect
151     * actual expression (nor its evaluation), rather they affect sorting
152     * of the result.
153     * <p>
154     * This method sets ordering by process manager name value.
155     *
156     * @param ascending
157     * @return itself
158     */

159    public ProcessMgrIteratorExpressionBuilder setOrderByName(boolean ascending);
160
161    /**
162     * Methods starting with <tt>setOrderBy</tt> obviously don't affect
163     * actual expression (nor its evaluation), rather they affect sorting
164     * of the result.
165     * <p>
166     * This method sets ordering by process manager version value.
167     *
168     * @param ascending
169     * @return itself
170     */

171    public ProcessMgrIteratorExpressionBuilder setOrderByVersion(boolean ascending);
172
173    /**
174     * Methods starting with <tt>setOrderBy</tt> obviously don't affect
175     * actual expression (nor its evaluation), rather they affect sorting
176     * of the result.
177     * <p>
178     * This method sets ordering by process manager created time value.
179     *
180     * @param ascending
181     * @return itself
182     */

183    public ProcessMgrIteratorExpressionBuilder setOrderByCreatedTime(boolean ascending);
184
185    /**
186     * Methods starting with <tt>setOrderBy</tt> obviously don't affect
187     * actual expression (nor its evaluation), rather they affect sorting
188     * of the result.
189     * <p>
190     * This method sets ordering by process manager enabled value.
191     *
192     * @param ascending
193     * @return itself
194     */

195    public ProcessMgrIteratorExpressionBuilder setOrderByEnabled(boolean ascending);
196 }
Popular Tags