|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectti.chimera.registry.TypeNodeContract
A NodeContract
which enforces that a value is an instanceof
a specified class.
Field Summary |
Fields inherited from interface ti.chimera.registry.NodeContract |
BOOLEAN_CONTRACT, NULL_CONTRACT, NUMBER_CONTRACT, STRING_CONTRACT |
Constructor Summary | |
TypeNodeContract(java.lang.Class type)
Class Constructor. |
Method Summary | |
boolean |
accepts(java.lang.Object value)
Determine if the specified value meets this contract. |
java.lang.Class |
getType()
Get the type. |
java.lang.String |
toString()
The contract implementation should overload toString so
the contract can be displayed to the user in a sane format, for use
in error messages, etc. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public TypeNodeContract(java.lang.Class type)
type
- the typeMethod Detail |
public boolean accepts(java.lang.Object value)
value
meets this contract.
accepts
in interface NodeContract
value
- the value to check
true
if meets contractpublic java.lang.Class getType()
public java.lang.String toString()
toString
so
the contract can be displayed to the user in a sane format, for use
in error messages, etc.
toString
in interface NodeContract
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |