|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.apache.tapestry.test.Creator
A utility class that is used to instantiate abstract Tapestry pages and components. It creates, at runtime, a subclass where all abstract properties are filled in (complete with instance variable, accessor and mutator methods). This isn't the same as how the class is enhanced at runtime, but is sufficient to unit test the class, especially listener methods.
Constructor Summary | |
Creator()
|
Method Summary | |
java.lang.Object |
newInstance(java.lang.Class abstractClass)
Given a particular abstract class; will create an instance of that class. |
java.lang.Object |
newInstance(java.lang.Class abstractClass,
java.util.Map properties)
Creates a new instance of a given class, and then initializes properties of the instance. |
java.lang.Object |
newInstance(java.lang.Class abstractClass,
java.lang.Object[] properties)
A convienience (useful in test code) for invoking newInstance(Class, Map) . |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public Creator()
Method Detail |
public java.lang.Object newInstance(java.lang.Class abstractClass)
public java.lang.Object newInstance(java.lang.Class abstractClass, java.util.Map properties)
public java.lang.Object newInstance(java.lang.Class abstractClass, java.lang.Object[] properties)
newInstance(Class, Map)
. The Map
is constructed from the properties array, which consists of alternating keys and values.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |