Revision 46498
trunk/org.gvsig.desktop/org.gvsig.desktop.library/org.gvsig.expressionevaluator/org.gvsig.expressionevaluator.geometry/org.gvsig.expressionevaluator.geometry.lib/org.gvsig.expressionevaluator.geometry.lib.impl/src/test/java/org/gvsig/expresionevaluator/impl/TestCompiler.java | ||
---|---|---|
158 | 158 |
operator("*"); |
159 | 159 |
operator("OR"); |
160 | 160 |
operator("AND"); |
161 |
operator("IS"); |
|
161 |
// operator("IS");
|
|
162 | 162 |
|
163 | 163 |
operator("~"); |
164 | 164 |
} |
trunk/org.gvsig.desktop/org.gvsig.desktop.library/org.gvsig.expressionevaluator/org.gvsig.expressionevaluator.lib/org.gvsig.expressionevaluator.lib.impl/src/test/java/org/gvsig/expresionevaluator/impl/TestCodeToValue.java | ||
---|---|---|
130 | 130 |
operator("OR"); |
131 | 131 |
operator("AND"); |
132 | 132 |
// operator("%"); |
133 |
operator("IS"); |
|
133 |
// operator("IS");
|
|
134 | 134 |
|
135 | 135 |
operator("~"); |
136 | 136 |
} |
trunk/org.gvsig.desktop/org.gvsig.desktop.library/org.gvsig.expressionevaluator/org.gvsig.expressionevaluator.lib/org.gvsig.expressionevaluator.lib.impl/src/test/java/org/gvsig/expresionevaluator/impl/TestCompiler.java | ||
---|---|---|
192 | 192 |
operator("*"); |
193 | 193 |
operator("OR"); |
194 | 194 |
operator("AND"); |
195 |
operator("IS"); |
|
195 |
// operator("IS");
|
|
196 | 196 |
|
197 | 197 |
operator("~"); |
198 | 198 |
} |
trunk/org.gvsig.desktop/org.gvsig.desktop.library/org.gvsig.expressionevaluator/org.gvsig.expressionevaluator.lib/org.gvsig.expressionevaluator.lib.impl/src/test/java/org/gvsig/expresionevaluator/impl/TestOptimizer.java | ||
---|---|---|
215 | 215 |
operator("OR"); |
216 | 216 |
operator("AND"); |
217 | 217 |
// operator("%"); |
218 |
operator("IS"); |
|
218 |
// operator("IS");
|
|
219 | 219 |
} |
220 | 220 |
|
221 | 221 |
|
trunk/org.gvsig.desktop/org.gvsig.desktop.library/org.gvsig.expressionevaluator/org.gvsig.expressionevaluator.lib/org.gvsig.expressionevaluator.lib.impl/src/test/java/org/gvsig/expresionevaluator/impl/TestCodeFormatter.java | ||
---|---|---|
360 | 360 |
operator("OR"); |
361 | 361 |
operator("AND"); |
362 | 362 |
// operator("%"); |
363 |
operator("IS"); |
|
363 |
// operator("IS");
|
|
364 | 364 |
|
365 | 365 |
operator("~"); |
366 | 366 |
} |
trunk/org.gvsig.desktop/org.gvsig.desktop.library/org.gvsig.expressionevaluator/org.gvsig.expressionevaluator.lib/org.gvsig.expressionevaluator.lib.impl/src/main/java/org/gvsig/expressionevaluator/impl/function/operator/IsOperator.java | ||
---|---|---|
21 | 21 |
@Override |
22 | 22 |
public Object call(Interpreter interpreter, Object op1, Object op2) { |
23 | 23 |
|
24 |
// FIXME: https://www.postgresql.org/docs/current/functions-comparison.html |
|
24 | 25 |
// FIXME: https://stackoverflow.com/questions/9822154/standard-sql-boolean-operator-is-vs-equals-operator |
25 | 26 |
|
26 | 27 |
int type = this.getType(op1, op2); |
trunk/org.gvsig.desktop/org.gvsig.desktop.library/org.gvsig.expressionevaluator/org.gvsig.expressionevaluator.lib/org.gvsig.expressionevaluator.lib.impl/src/main/java/org/gvsig/expressionevaluator/impl/DefaultCompiler.java | ||
---|---|---|
385 | 385 |
lexer.next(); |
386 | 386 |
op1 = codeBuilder.is(op1, codeBuilder.constant(null)); |
387 | 387 |
} else { |
388 |
op2 = parse_sum(); |
|
389 |
if( op2==null ) { |
|
388 |
// FIXME: https://www.postgresql.org/docs/current/functions-comparison.html |
|
389 |
// FIXME: Deberiamos soportar solo las constantes TRUE y FALSE |
|
390 |
// op2 = parse_sum(); |
|
391 |
// if( op2==null ) { |
|
390 | 392 |
throw new ExpressionSyntaxException(I18N.Cant_recognize_the_second_operand_of_IS_operator(),lexer); |
391 |
} |
|
392 |
op1 = codeBuilder.is(op1, op2); |
|
393 |
// }
|
|
394 |
// op1 = codeBuilder.is(op1, op2);
|
|
393 | 395 |
} |
394 | 396 |
op1 = codeBuilder.not(op1); |
395 | 397 |
break; |
... | ... | |
398 | 400 |
op1 = codeBuilder.is(op1, codeBuilder.constant(null)); |
399 | 401 |
break; |
400 | 402 |
default: |
401 |
op2 = parse_sum(); |
|
402 |
if( op2==null ) { |
|
403 |
// FIXME: https://www.postgresql.org/docs/current/functions-comparison.html |
|
404 |
// FIXME: Deberiamos soportar solo las constantes TRUE y FALSE |
|
405 |
// op2 = parse_sum(); |
|
406 |
// if( op2==null ) { |
|
403 | 407 |
throw new ExpressionSyntaxException(I18N.Cant_recognize_the_second_operand_of_IS_operator(),lexer); |
404 |
} |
|
405 |
op1 = codeBuilder.is(op1, op2); |
|
408 |
// }
|
|
409 |
// op1 = codeBuilder.is(op1, op2);
|
|
406 | 410 |
} |
407 | 411 |
} |
408 | 412 |
break; |
Also available in: Unified diff