java.lang.Object
org.bigraphs.framework.core.reactivesystem.ReactiveSystemPredicate<B>
org.bigraphs.framework.simulation.modelchecking.predicates.AndPredicate<B>
public class AndPredicate<B extends Bigraph<? extends Signature<?>>>
extends ReactiveSystemPredicate<B>
A composite predicate which concatenates all given predicates with the and operator.
- Author:
- Dominik Grzelak
-
Field Summary
Fields inherited from class org.bigraphs.framework.core.reactivesystem.ReactiveSystemPredicate
label, negate -
Constructor Summary
ConstructorsConstructorDescriptionAndPredicate(boolean negate, ReactiveSystemPredicate<B>... predicates) AndPredicate(ReactiveSystemPredicate<B>... predicates) AndPredicate(ReactiveSystemPredicate<B> predicateA, ReactiveSystemPredicate<B> predicateB) AndPredicate(ReactiveSystemPredicate<B> predicateA, ReactiveSystemPredicate<B> predicateB, boolean negate) -
Method Summary
Modifier and TypeMethodDescriptionGet the bigraph used in the predicate.booleanConcatenates all given predicates with the and operator of theReactiveSystemPredicateclass and evaluates them together.Methods inherited from class org.bigraphs.framework.core.reactivesystem.ReactiveSystemPredicate
getLabel, isNegate, setNegate, withLabel
-
Constructor Details
-
AndPredicate
-
AndPredicate
public AndPredicate(ReactiveSystemPredicate<B> predicateA, ReactiveSystemPredicate<B> predicateB, boolean negate) -
AndPredicate
-
AndPredicate
-
-
Method Details
-
getBigraph
Description copied from class:ReactiveSystemPredicateGet the bigraph used in the predicate. If the predicate is a conditional predicate, the methid returnsnull.- Specified by:
getBigraphin classReactiveSystemPredicate<B extends Bigraph<? extends Signature<?>>>- Returns:
- the underlying bigraph of the predicate, or
nullfor conditional predicates.
-
test
Concatenates all given predicates with the and operator of theReactiveSystemPredicateclass and evaluates them together.Note: if the predicate set is empty,
truewill be returned also.- Specified by:
testin interfacePredicate<B extends Bigraph<? extends Signature<?>>>- Specified by:
testin classReactiveSystemPredicate<B extends Bigraph<? extends Signature<?>>>- Parameters:
agent- the current state of a transition system of a BRS to test the predicate against- Returns:
true, if the consolidated predicates evaluate totrue(or predicate list is empty), otherwisefalse.
-