Revision 46505 trunk/org.gvsig.desktop/org.gvsig.desktop.library/org.gvsig.expressionevaluator/org.gvsig.expressionevaluator.lib/org.gvsig.expressionevaluator.lib.api/src/main/java/org/gvsig/expressionevaluator/ExpressionBuilder.java
ExpressionBuilder.java | ||
---|---|---|
1 | 1 |
package org.gvsig.expressionevaluator; |
2 | 2 |
|
3 | 3 |
import java.awt.Color; |
4 |
import java.util.Collections; |
|
4 | 5 |
import java.util.Date; |
5 | 6 |
import java.util.List; |
6 | 7 |
import java.util.Map; |
... | ... | |
142 | 143 |
|
143 | 144 |
public interface VisitorFilter { |
144 | 145 |
boolean accept(Visitable visitable); |
146 |
default boolean skipChildren() { return false; } |
|
145 | 147 |
} |
146 | 148 |
|
147 | 149 |
public interface Visitor { |
... | ... | |
170 | 172 |
public Object value(); |
171 | 173 |
} |
172 | 174 |
|
175 |
public static final Constant VALUE_NULL = new Constant() { |
|
176 |
@Override |
|
177 |
public Object value() { |
|
178 |
return null; |
|
179 |
} |
|
180 |
|
|
181 |
@Override |
|
182 |
public String toString() { |
|
183 |
return "NULL"; |
|
184 |
} |
|
185 |
|
|
186 |
@Override |
|
187 |
public String toString(Formatter<Value> formatter) { |
|
188 |
return "NULL"; |
|
189 |
} |
|
190 |
|
|
191 |
@Override |
|
192 |
public void replace(Value target, Value replacement) { |
|
193 |
} |
|
194 |
|
|
195 |
@Override |
|
196 |
public void copyPropertiesFrom(PropertiesSupport properties) { |
|
197 |
} |
|
198 |
|
|
199 |
@Override |
|
200 |
@SuppressWarnings("CloneDoesntCallSuperClone") |
|
201 |
public Value clone() throws CloneNotSupportedException { |
|
202 |
return this; |
|
203 |
} |
|
204 |
|
|
205 |
@Override |
|
206 |
public void accept(Visitor visitor, VisitorFilter filter) { |
|
207 |
} |
|
208 |
|
|
209 |
@Override |
|
210 |
public Object getProperty(String name) { |
|
211 |
return null; |
|
212 |
} |
|
213 |
|
|
214 |
@Override |
|
215 |
public void setProperty(String name, Object value) { |
|
216 |
} |
|
217 |
|
|
218 |
@Override |
|
219 |
public Map<String, Object> getProperties() { |
|
220 |
return Collections.EMPTY_MAP; |
|
221 |
} |
|
222 |
}; |
|
223 |
|
|
173 | 224 |
public interface Custom extends Value { |
174 | 225 |
public Object value(); |
175 | 226 |
public Custom add(Variable variable); |
Also available in: Unified diff