org.hypergraphdb.type.javaprimitive
Class PrimitiveArrayType

java.lang.Object
  extended by org.hypergraphdb.type.javaprimitive.PrimitiveArrayType
All Implemented Interfaces:
HGGraphHolder, HGAtomType
Direct Known Subclasses:
BooleanPrimitiveArrayType, BytePrimitiveArrayType, CharPrimitiveArrayType, DoublePrimitiveArrayType, FloatPrimitiveArrayType, IntPrimitiveArrayType, LongPrimitiveArrayType, ShortPrimitiveArrayType

public abstract class PrimitiveArrayType
extends java.lang.Object
implements HGAtomType


Constructor Summary
PrimitiveArrayType()
           
 
Method Summary
 void release(HGPersistentHandle handle)
          Release a hypergraph value instance from the persistent store.
 void setHyperGraph(HyperGraph hg)
          During load time, set the HyperGraph instance to which this atom belongs.
 boolean subsumes(java.lang.Object general, java.lang.Object specific)
          A generic semantic predicate that returns true if the first argument is more general than the second.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.hypergraphdb.type.HGAtomType
make, store
 

Constructor Detail

PrimitiveArrayType

public PrimitiveArrayType()
Method Detail

setHyperGraph

public void setHyperGraph(HyperGraph hg)
Description copied from interface: HGGraphHolder

During load time, set the HyperGraph instance to which this atom belongs.

Specified by:
setHyperGraph in interface HGGraphHolder

release

public void release(HGPersistentHandle handle)
Description copied from interface: HGAtomType

Release a hypergraph value instance from the persistent store.

This method should be called when a HGPersistentHandle returned from the store is no longer in use.

Specified by:
release in interface HGAtomType
Parameters:
handle - The persistent handle of the value to release.

subsumes

public boolean subsumes(java.lang.Object general,
                        java.lang.Object specific)
Description copied from interface: HGAtomType

A generic semantic predicate that returns true if the first argument is more general than the second. Atom types must implement this notion of specialization whenever meaningful in the context of the entities being constructed.

The notion of subsumption can be seen as partial equivalence, or equivalence in one direction only.

As a relation, subsumtion is transitive and reflexive. The latter implies that, at a minimum, the subsumes method must return true if general.equals(specific).

Specified by:
subsumes in interface HGAtomType
Parameters:
general - The object which might be more general. Cannot be null.
specific - The object which might be more specific. Cannot be null.
Returns:
true if specific can be used whenever general is required and false otherwise.