public abstract class PredicateMessageRule extends AbstractMessageRule implements PredicateRuleSupport<Message>
Constructor and Description |
---|
PredicateMessageRule(Predicate predicate,
Expression<Message> expression)
Create a new message rule
|
Modifier and Type | Method and Description |
---|---|
ValidationException[] |
apply(Message msg)
Applies to rule to an object to be checked
|
Predicate |
getPredicate() |
test
failed, failed, failed, failed, failedWithValue, getDescription, getErrorCode, getSectionReference, getSeverity, passed, result, result, setDescription, setErrorCode, setSectionReference, setSeverity
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getDescription, getSectionReference
public PredicateMessageRule(Predicate predicate, Expression<Message> expression)
predicate
- the predicate to be used for the testexpression
- the expression to be used to extract the message part
to be testedpublic ValidationException[] apply(Message msg)
Rule
public Predicate getPredicate()
getPredicate
in interface PredicateRuleSupport<Message>
Copyright © 2001–2017 University Health Network. All rights reserved.