mockpp::OutBound< T > Class Template Reference
[Parameter Constraints]

Passes a value back via a reference (outbound value). More...

Inheritance diagram for mockpp::OutBound< T >:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 OutBound (const T &retArg)
 Constructs the object.
template<class I >
 OutBound (I items, I end)
 Constructs the object base on a list of values.
void addOutboundObject (const T &retArg)
 Adds another return value.
template<class I >
OutBoundaddOutboundObject (I items, I end)
 Add a sequence of next objects to the end of the list.
virtual ~OutBound ()
 Destroys the object.
virtual bool eval (const T &arg) const
 Evaluates the constraint.
virtual bool verify (const T &) const
 Evaluates the constraint at the end.
virtual String describeTo (String &buffer) const
 Appends the description of this object to the buffer.

Detailed Description

template<typename T>
class mockpp::OutBound< T >

Passes a value back via a reference (outbound value).

Warning:
Be extremely careful when using OutBound in conjunction with other contraints using And or Or as side effects might occur.

Definition at line 49 of file OutBound.h.


Constructor & Destructor Documentation

template<typename T >
mockpp::OutBound< T >::OutBound ( const T &  retArg  )  [inline]

Constructs the object.

Parameters:
retArg the first value to return

Definition at line 56 of file OutBound.h.

template<typename T >
template<class I >
mockpp::OutBound< T >::OutBound ( items,
end 
) [inline]

Constructs the object base on a list of values.

Parameters:
items start iterator
end terminating iterator (note: one element "behind" as always with STL)

Definition at line 67 of file OutBound.h.


Member Function Documentation

template<typename T >
template<class I >
OutBound& mockpp::OutBound< T >::addOutboundObject ( items,
end 
) [inline]

Add a sequence of next objects to the end of the list.

Parameters:
items start iterator
end terminating iterator (note: one element "behind" as always with STL)
Returns:
reference to itself for chaining

Definition at line 87 of file OutBound.h.

template<typename T >
void mockpp::OutBound< T >::addOutboundObject ( const T &  retArg  )  [inline]

Adds another return value.

Parameters:
retArg the next value to return

Definition at line 76 of file OutBound.h.

template<typename T >
virtual String mockpp::OutBound< T >::describeTo ( String buffer  )  const [inline, virtual]

Appends the description of this object to the buffer.

Parameters:
buffer The buffer that the description is appended to.
Returns:
The current content of the buffer data

Implements mockpp::SelfDescribing.

Definition at line 131 of file OutBound.h.

template<typename T >
virtual bool mockpp::OutBound< T >::eval ( const T &  arg  )  const [inline, virtual]

Evaluates the constraint.

The value is not actually evaluated but a value is returned.

Parameters:
arg the object which is passed the value.
Returns:
true: at least one return object is avaliable
false: no more return objects are avaliable

Implements mockpp::Constraint< T >.

Definition at line 105 of file OutBound.h.

template<typename T >
virtual bool mockpp::OutBound< T >::verify ( const T &   )  const [inline, virtual]

Evaluates the constraint at the end.

Parameters:
arg the object which is passed the value.
Returns:
true: All values must have been consumed.
false: At least one object is still available

Reimplemented from mockpp::Constraint< T >.

Definition at line 122 of file OutBound.h.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Friends Defines

Generated on Tue Jan 5 09:49:07 2010 for mockpp by  doxygen 1.6.1