Revision 43610 trunk/org.gvsig.desktop/org.gvsig.desktop.compat.cdc/org.gvsig.fmap.mapcontext/org.gvsig.fmap.mapcontext.api/src/main/java/org/gvsig/fmap/mapcontext/layers/vectorial/IntersectsTimeEvaluator.java
IntersectsTimeEvaluator.java | ||
---|---|---|
48 | 48 |
|
49 | 49 |
public Object evaluate(EvaluatorData data) throws EvaluatorException { |
50 | 50 |
Feature feature = ((Feature) data.getContextValue("feature")); |
51 |
Time featureTime = (Time)feature.get(timeAttributeName);
|
|
52 |
if( featureTime==null ) {
|
|
53 |
return Boolean.FALSE;
|
|
51 |
Object value = feature.get(timeAttributeName);
|
|
52 |
if( !(value instanceof Time) ) {
|
|
53 |
return false;
|
|
54 | 54 |
} |
55 |
return new Boolean(time.intersects(featureTime)); |
|
55 |
Time featureTime = (Time)value; |
|
56 |
return time.intersects(featureTime); |
|
56 | 57 |
} |
57 | 58 |
|
58 | 59 |
public String getName() { |
Also available in: Unified diff