Interface Verifiable

All Known Subinterfaces:
All Known Implementing Classes:
ActivityCore, BooleanVector, ByteVector, CharVector, ConstVector, DNSName, DNSRecord, DoubleVector, FilterStorage, FloatVector, HashedStorage, IntStorage, IntVector, ListStorage, LongVector, ObjectStorage, ObjectVector, ObservedCore, ShortVector, SortedStorage, Storage, StorageEnumerator, StorageEvent, TreeStorage

public interface Verifiable

Interface for object self-integrity check. A class implementing this interface gives the programmer (or, mainly, the debugger) the opportunity to check the consistency of internal structures of the object of such class. If there is nothing to check in some class then the class should not implement this interface.

Ivan Maidanski

Method Summary
 void integrityCheck()
          Verifies this object for its integrity.

Method Detail


void integrityCheck()
Verifies this object for its integrity. This method is mostly used for debug purpose only. By default, deep integrity (internal consistency) check is performed (that is, all variable fields of this object are verified too). Internal state of object is not altered. If internal consistency is violated somehow (due to an error in Java VM or due to a programmer error) then InternalError is thrown (with some detailed message). Important notes: static final fields should not be checked. This method should be synchronized outside (unless the object is not mutable).

java.lang.InternalError - if integrity violation is detected.