|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object th.co.edge.jseq.MockObjectMap
public class MockObjectMap
A MockObjectMap
is a mapping from names to
MockObject
s, with utility methods to make it easy to
translate from Activation
s to MockObject
s,
with automatic handling of column numbers.
Constructor Summary | |
---|---|
MockObjectMap()
|
Method Summary | |
---|---|
void |
add(MockObjectMap otherObjectMap)
Ensures that all MockObject s in another
MockObjectMap is also in this map. |
static MockObjectMap |
addAll(Activation activation)
Returns a new MockObjectMap where the method calls
represented by the given Activation and its nested
activations have been added as MockObject s to this map,
with the activation method call first, and the nested method calls in the
order they were added to the activation. |
MockObject |
get(java.lang.String name)
Returns the MockObject associated with the given name, or
null if there is none. |
java.util.List<MockObject> |
listView()
Returns a list of all MockObject s in this map, ordered by
column number (and name if the same column number occurs several times,
which it normally should not do). |
java.lang.String |
toString()
Returns a string representation of this MockObjectMap ,
mainly useful for logging. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public MockObjectMap()
Method Detail |
---|
public void add(MockObjectMap otherObjectMap)
MockObject
s in another
MockObjectMap
is also in this map.
otherObjectMap
- the MockObjectMap
whose MockObject
s
to add to this map if necessarypublic static MockObjectMap addAll(Activation activation)
MockObjectMap
where the method calls
represented by the given Activation
and its nested
activations have been added as MockObject
s to this map,
with the activation method call first, and the nested method calls in the
order they were added to the activation.
activation
- the Activation
whose method call and nested
method calls to add to this map
MockObjectMap
containing all method calls
from activation
public MockObject get(java.lang.String name)
MockObject
associated with the given name, or
null
if there is none.
name
- the name of the MockObject
to look up
MockObject
associated with name
,
or null
if there is nonepublic java.util.List<MockObject> listView()
MockObject
s in this map, ordered by
column number (and name if the same column number occurs several times,
which it normally should not do).
MockObject
s in this mappublic java.lang.String toString()
MockObjectMap
,
mainly useful for logging.
toString
in class java.lang.Object
MockObjectMap
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |