Package com.luciad.ogc.filter.model
Class TLcdOGCBinaryLogicOperator
java.lang.Object
com.luciad.datamodel.TLcdDataObject
com.luciad.ogc.filter.model.TLcdOGCBinaryLogicOperator
- All Implemented Interfaces:
ILcdDataObject
,ILcdGenericExpression
,ILcdOGCCondition
,ILcdCloneable
,ILcdDeepCloneable
,Cloneable
This class represents the elements of type
<ogc:BinaryLogicOpType>
.
Namely:
<ogc:And>
<ogc:Or>
TLcdOGCBinaryLogicOperator
instance is composed of a logic operation type that must be one of the constants
defined in this class and two or more ILcdOGCCondition
instances that represents the condition operands.-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionDefault constructor.TLcdOGCBinaryLogicOperator
(int aType) Constructs an instance for a given logic operation type.TLcdOGCBinaryLogicOperator
(int aType, ILcdOGCCondition... aConditions) Constructs an instance for a given logic operation type and the given operands. -
Method Summary
Modifier and TypeMethodDescriptionvoid
addCondition
(ILcdOGCCondition aCondition) Adds a condition.boolean
getCondition
(int aIndex) Gets the condition at a given position.int
Gets the number of condition operands.Returns the conditions for this operatorint
getType()
Gets the given logic operation type.int
hashCode()
void
insertConditionAt
(ILcdOGCCondition aCondition, int aIndex) Inserts a condition at a given position.boolean
removeCondition
(ILcdOGCCondition aCondition) Removes a condition.void
setType
(int aType) Sets the given logic operation type.toString()
Methods inherited from class com.luciad.datamodel.TLcdDataObject
clone, clone, getDataType, getValue, getValue, hasValue, hasValue, setValue, setValue
-
Field Details
-
AND
public static final int ANDLogic operation type that corresponds to the<ogc:And>
element.- See Also:
-
OR
public static final int ORLogic operation type that corresponds to the<ogc:Or>
element.- See Also:
-
-
Constructor Details
-
TLcdOGCBinaryLogicOperator
public TLcdOGCBinaryLogicOperator()Default constructor. -
TLcdOGCBinaryLogicOperator
public TLcdOGCBinaryLogicOperator(int aType) Constructs an instance for a given logic operation type.- Parameters:
aType
- the logic operation type. It must be one of the constants of this class.
-
TLcdOGCBinaryLogicOperator
Constructs an instance for a given logic operation type and the given operands.- Parameters:
aType
- the logic operation type. It must be one of the constants of this class.aConditions
- the condition operands
-
-
Method Details
-
getType
public int getType()Gets the given logic operation type.- Returns:
- the given logic operation type. It will be one of the constants of this class.
-
setType
public void setType(int aType) Sets the given logic operation type. It must be one of the constants of this class.- Parameters:
aType
- the given logic operation type.
-
removeCondition
Removes a condition.- Parameters:
aCondition
- the condition to be removed.- Returns:
- true if
aCondition
was an operand of the logic operator; false otherwise.
-
getConditions
Returns the conditions for this operator- Returns:
- the list of conditions for this operator
-
insertConditionAt
Inserts a condition at a given position.- Parameters:
aCondition
- the condition of the operand to be inserted.aIndex
- the index of the given position.
-
addCondition
Adds a condition.- Parameters:
aCondition
- the condition to be added.
-
getConditionCount
public int getConditionCount()Gets the number of condition operands.- Returns:
- the number of condition operands.
-
getCondition
Gets the condition at a given position.- Parameters:
aIndex
- the index of the given position.- Returns:
- the condition.
-
equals
-
hashCode
public int hashCode() -
toString
- Overrides:
toString
in classTLcdDataObject
-