Class ConditionBase
java.lang.Object
adaa.analytics.rules.logic.representation.condition.ConditionBase
- All Implemented Interfaces:
Serializable,Cloneable
- Direct Known Subclasses:
CompoundCondition,ElementaryCondition
Abstract base class representing all conditions.
- See Also:
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected IntegerBitSetOptional integer bit set for storing condition coverage.protected booleanFlag indicating if condition is disabled.protected ConditionBase.TypeCondition type. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract ConditionBaseclone()abstract booleanVerifies whether the condition is equal to another one.voidevaluate(IExampleSet set, Set<Integer> outIndices) Evaluates the condition on a specified dataset.booleanEvaluates the condition on a given example.Gets a collection of attributes the condition is built upon.Getscovering.getType()Getstypeprotected abstract voidinternalEvaluate(IExampleSet set, Set<Integer> outIndices) Evaluates the condition on a specified dataset.protected abstract booleanEvaluates the condition on a given example.booleanGetsdisabledbooleanCheck whether the condition is prunable (non-FORCED and non-PREFERRED).voidSetscovering.voidsetDisabled(boolean b) SetsdisabledvoidSetstype
-
Field Details
-
disabled
protected boolean disabledFlag indicating if condition is disabled. -
type
Condition type. -
covering
Optional integer bit set for storing condition coverage.
-
-
Constructor Details
-
ConditionBase
public ConditionBase()
-
-
Method Details
-
isDisabled
public boolean isDisabled()Getsdisabled -
setDisabled
public void setDisabled(boolean b) Setsdisabled -
getType
Getstype -
setType
Setstype -
getCovering
Getscovering. -
setCovering
Setscovering. -
isPrunable
public boolean isPrunable()Check whether the condition is prunable (non-FORCED and non-PREFERRED).- Returns:
- Value indicating whether condition is prunable.
-
evaluate
Evaluates the condition on a given example. It verifiesdisabledflag and callsinternalEvaluate(adaa.analytics.rules.data.row.Example)abstract method.- Parameters:
ex- Example to be examined.- Returns:
- Logical value indicating whether the example fulfills the condition.
-
evaluate
Evaluates the condition on a specified dataset. It verifiesdisabledflag and callsinternalEvaluate(adaa.analytics.rules.data.row.Example)abstract method.- Parameters:
set- Input dataset.outIndices- Output set of indices covered by the condition.
-
equals
Verifies whether the condition is equal to another one. -
getAttributes
Gets a collection of attributes the condition is built upon.- Returns:
- Set of attributes.
-
internalEvaluate
Evaluates the condition on a given example.- Parameters:
ex- Example to be examined.- Returns:
- Logical value indicating whether the example fulfills the condition.
-
internalEvaluate
Evaluates the condition on a specified dataset.- Parameters:
set- Input dataset.outIndices- Output set of indices covered by the condition.
-
clone
-