Class AndConditionService
- java.lang.Object
-
- org.eclipse.emf.ecp.view.internal.rule.AndConditionService
-
- All Implemented Interfaces:
ConditionService<AndCondition>
public class AndConditionService extends java.lang.Object implements ConditionService<AndCondition>
ConditionService
for conditions of typeAndCondition
.
-
-
Constructor Summary
Constructors Constructor Description AndConditionService()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
activate(org.osgi.framework.BundleContext bundleContext)
Called by the framework when the component gets activated.protected void
deactivate(org.osgi.framework.BundleContext bundleContext)
Called by the framework when the component gets deactivated.boolean
evaluate(AndCondition condition, org.eclipse.emf.ecore.EObject domainModel)
Evaluates the given condition.boolean
evaluateChangedValues(AndCondition condition, org.eclipse.emf.ecore.EObject domainModel, java.util.Map<org.eclipse.emf.ecore.EStructuralFeature.Setting,java.lang.Object> possibleNewValues)
Evaluates the given condition.java.util.Set<UniqueSetting>
getConditionSettings(AndCondition condition, org.eclipse.emf.ecore.EObject domainModel)
The set ofUniqueSetting
that are relevant for the provided condition and domain model.org.eclipse.emf.ecore.EClass
getConditionType()
The EClass this ConditionService is implemented for.java.util.Set<VDomainModelReference>
getDomainModelReferences(AndCondition condition)
The Set ofVDomainModelReference
that are relevant for the condition.
-
-
-
Method Detail
-
getConditionType
public org.eclipse.emf.ecore.EClass getConditionType()
Description copied from interface:ConditionService
The EClass this ConditionService is implemented for.- Specified by:
getConditionType
in interfaceConditionService<AndCondition>
- Returns:
- The EClass of the
Condition
-
getConditionSettings
public java.util.Set<UniqueSetting> getConditionSettings(AndCondition condition, org.eclipse.emf.ecore.EObject domainModel)
Description copied from interface:ConditionService
The set ofUniqueSetting
that are relevant for the provided condition and domain model.- Specified by:
getConditionSettings
in interfaceConditionService<AndCondition>
- Parameters:
condition
- TheCondition
to get the UniqueSettings fordomainModel
- TheEObject
to use for retrieving- Returns:
- The Set of UniqueSettings. This Set must not be null.
-
evaluate
public boolean evaluate(AndCondition condition, org.eclipse.emf.ecore.EObject domainModel)
Description copied from interface:ConditionService
Evaluates the given condition.- Specified by:
evaluate
in interfaceConditionService<AndCondition>
- Parameters:
condition
- The Condition to evaluatedomainModel
- The root domain object of this condition.- Returns:
true
, if the condition matches,false
otherwise
-
evaluateChangedValues
public boolean evaluateChangedValues(AndCondition condition, org.eclipse.emf.ecore.EObject domainModel, java.util.Map<org.eclipse.emf.ecore.EStructuralFeature.Setting,java.lang.Object> possibleNewValues)
Description copied from interface:ConditionService
Evaluates the given condition.- Specified by:
evaluateChangedValues
in interfaceConditionService<AndCondition>
- Parameters:
condition
- The Condition to evaluatedomainModel
- The root domain object of this condition.possibleNewValues
- the new value that should be compared against the expected value of the condition- Returns:
true
, if the condition matches,false
otherwise
-
getDomainModelReferences
public java.util.Set<VDomainModelReference> getDomainModelReferences(AndCondition condition)
Description copied from interface:ConditionService
The Set ofVDomainModelReference
that are relevant for the condition.- Specified by:
getDomainModelReferences
in interfaceConditionService<AndCondition>
- Parameters:
condition
- TheCondition
to retrieve the VDMRs for- Returns:
- The Set of VDomainModelReferences. This Set must not be null.
-
activate
protected void activate(org.osgi.framework.BundleContext bundleContext)
Called by the framework when the component gets activated.- Parameters:
bundleContext
- TheBundleContext
-
deactivate
protected void deactivate(org.osgi.framework.BundleContext bundleContext)
Called by the framework when the component gets deactivated.- Parameters:
bundleContext
- TheBundleContext
-
-