Logo Search packages:      
Sourcecode: jmock2 version File versions  Download package

org::jmock::internal::ReturnDefaultValueAction Class Reference

Inheritance diagram for org::jmock::internal::ReturnDefaultValueAction:

org::jmock::api::Action org::jmock::api::Invokable

List of all members.


Detailed Description

Returns a value of the invoked method's result type. Returns nothing from void methods. Zero or false results are returned for primitive types. Arrays and strings are returned with a length of zero. Types that can be imposterised by the action's Imposteriser are returned as Null Objects. Otherwise null is returned. The default value can be overridden for specific types.

Author:
nat

Definition at line 27 of file ReturnDefaultValueAction.java.


Public Member Functions

void addResult (Class<?> resultType, Object resultValue)
void describeTo (Description description)
Object invoke (Invocation invocation) throws Throwable
 ReturnDefaultValueAction (Imposteriser imposteriser)
void setImposteriser (Imposteriser newImposteriser)

Protected Member Functions

void createDefaultResults ()

Private Attributes

Imposteriser imposteriser
final Map< Class<?>, Object > resultValuesByType = new HashMap<Class<?>, Object>()

The documentation for this class was generated from the following file:

Generated by  Doxygen 1.6.0   Back to index