class inSequence

class inSequence(repetition : CallConstraint)

 extends ProtocolType

The inSequence protocol type will try to consume expected calls in sequence. It will not consume unexpected calls.
It accepts a repetition parameter specifying how many expected calls are supposed to happen:

Companion: inSequence

Source: InSequence.scala(15)

Direct Known Subclasses



def this(repetition : CallConstraint)


constraints def constraints
- a String specifying the constraints of this protocol: e.g. "in sequence 2 of:". If it is exactly one, returns "in sequence"


!= final def !=(arg0 : Any) Boolean Any
!= final def !=(arg0 : Object) Boolean AnyRef
== final def ==(arg0 : Object) Boolean AnyRef
== final def ==(arg0 : Any) Boolean Any
asInstanceOf final def asInstanceOf[T0] T0 Any
clone protected def clone Object AnyRef
consume def consume(exp : List[SpecifiedCall], rec : List[ReceivedCall])
Tries to match expected calls with received calls in sequence until the repetition parameter is satisfied [details]

Before doing so, it sets the repetition number on expected calls, so that they know when to stop matching received calls (especially for atLeast and atMost constraints).
If consumed received calls are not in the same order as their respective expected calls it resets them so that the received calls are not consumed and the expected calls are not passed
- the list of expected calls and the list of received calls
(List[SpecifiedCall], List[ReceivedCall])
eq final def eq(arg0 : Object) Boolean AnyRef
equals override def equals(other : Any) Boolean ProtocolType
expectedDefs def expectedDefs(expected : List[SpecifiedCall])
- a user message specifying the protocol constraints on the expected calls: for example "in any order m1; m2" or "in sequence m1; m2; m3"
String ProtocolType
failures def failures(expected : List[SpecifiedCall], received : List[ReceivedCall], exclusive : Boolean)
- also an error message when unexpected calls occured if exclusive is true
- "" otherwise
- error messages specifying if some expected calls have not been met.
String ProtocolType
finalize protected def finalize Unit AnyRef
getClass final def getClass Class[Object] AnyRef
hashCode def hashCode Int AnyRef
isInstanceOf final def isInstanceOf[T0] Boolean Any
ne final def ne(arg0 : Object) Boolean AnyRef
notify final def notify Unit AnyRef
notifyAll final def notifyAll Unit AnyRef
receivedMessages def receivedMessages(received : List[ReceivedCall])
- a user message with the list of received messages
String ProtocolType
synchronized final def synchronized[T0](arg0 : T0) T0 AnyRef
toString def toString String AnyRef
wait final def wait(arg0 : Long) Unit AnyRef
wait final def wait Unit AnyRef
wait final def wait(arg0 : Long, arg1 : Int) Unit AnyRef
Copyright (c) 2007-2009. All Rights Reserved.