ti.chimera.registry
Class ImmutableNodeContract

java.lang.Object
  extended byti.chimera.registry.ImmutableNodeContract
All Implemented Interfaces:
NodeContract

public class ImmutableNodeContract
extends java.lang.Object
implements NodeContract

A NodeContract which will not allow the node's value to be changed. In other words, it accepts only the first value.

Version:
0.1
Author:
;Rob Clark;a0873619;San Diego;;

Field Summary
 
Fields inherited from interface ti.chimera.registry.NodeContract
BOOLEAN_CONTRACT, NULL_CONTRACT, NUMBER_CONTRACT, STRING_CONTRACT
 
Constructor Summary
ImmutableNodeContract()
           
 
Method Summary
 boolean accepts(java.lang.Object value)
          Determine if the specified value meets this contract.
 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

ImmutableNodeContract

public ImmutableNodeContract()
Method Detail

accepts

public boolean accepts(java.lang.Object value)
Determine if the specified value meets this contract.

Specified by:
accepts in interface NodeContract
Parameters:
value - the value to check
Returns:
true if meets contract

toString

public 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.

Specified by:
toString in interface NodeContract