Package org.apache.camel.component.mock
Class TimeClause
- java.lang.Object
-
- org.apache.camel.component.mock.TimeClause
-
- All Implemented Interfaces:
org.apache.camel.BinaryPredicate,org.apache.camel.Predicate
public class TimeClause extends Object implements org.apache.camel.BinaryPredicate
Represents time based clauses for setting expectations on the mocks. Such as time constrains for the received messages.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description classTimeClause.TimeClassUnit
-
Constructor Summary
Constructors Constructor Description TimeClause(org.apache.camel.Expression left, org.apache.camel.Expression right)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidafterPrevious()voidbeforeNext()TimeClause.TimeClassUnitbetween(int from, int to)org.apache.camel.ExpressiongetLeft()protected StringgetOperationText()StringgetOperator()org.apache.camel.ExpressiongetRight()booleanmatches(org.apache.camel.Exchange exchange)protected booleanmatches(org.apache.camel.Exchange exchange, Object leftValue, Object rightValue)StringmatchesReturningFailureMessage(org.apache.camel.Exchange exchange)TimeClause.TimeClassUnitnoLaterThan(int period)StringtoString()
-
-
-
Method Detail
-
noLaterThan
public TimeClause.TimeClassUnit noLaterThan(int period)
-
between
public TimeClause.TimeClassUnit between(int from, int to)
-
beforeNext
public void beforeNext()
-
afterPrevious
public void afterPrevious()
-
getLeft
public org.apache.camel.Expression getLeft()
- Specified by:
getLeftin interfaceorg.apache.camel.BinaryPredicate
-
getRight
public org.apache.camel.Expression getRight()
- Specified by:
getRightin interfaceorg.apache.camel.BinaryPredicate
-
matches
public boolean matches(org.apache.camel.Exchange exchange)
- Specified by:
matchesin interfaceorg.apache.camel.Predicate
-
matchesReturningFailureMessage
public String matchesReturningFailureMessage(org.apache.camel.Exchange exchange)
- Specified by:
matchesReturningFailureMessagein interfaceorg.apache.camel.BinaryPredicate
-
matches
protected boolean matches(org.apache.camel.Exchange exchange, Object leftValue, Object rightValue)
-
getOperator
public String getOperator()
- Specified by:
getOperatorin interfaceorg.apache.camel.BinaryPredicate
-
getOperationText
protected String getOperationText()
-
-