Package com.db4o.typehandlers.internal
Class TreeSetTypeHandler
- java.lang.Object
-
- com.db4o.typehandlers.internal.TreeSetTypeHandler
-
- All Implemented Interfaces:
InstantiatingTypeHandler
,QueryableTypeHandler
,ReferenceTypeHandler
,TypeHandler4
public abstract class TreeSetTypeHandler extends java.lang.Object implements InstantiatingTypeHandler, QueryableTypeHandler
-
-
Constructor Summary
Constructors Constructor Description TreeSetTypeHandler()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description void
activate(ReferenceActivationContext context)
gets called when an object is to be activated.protected abstract java.util.TreeSet
create(java.util.Comparator comparator)
void
defragment(DefragmentContext context)
gets called when an object gets defragmented.void
delete(DeleteContext context)
gets called when an object gets deleted.boolean
descendsIntoMembers()
java.lang.Object
instantiate(ReadContext context)
void
write(WriteContext context, java.lang.Object obj)
gets called when an object is to be written to the database.void
writeInstantiation(WriteContext context, java.lang.Object obj)
gets called when an object is to be written to the database.
-
-
-
Method Detail
-
descendsIntoMembers
public boolean descendsIntoMembers()
- Specified by:
descendsIntoMembers
in interfaceQueryableTypeHandler
-
writeInstantiation
public void writeInstantiation(WriteContext context, java.lang.Object obj)
Description copied from interface:InstantiatingTypeHandler
gets called when an object is to be written to the database. The method must only write data necessary to re instantiate the object, usually the immutable bits of information held by the object. For value types that means their complete state. Mutable state (only allowed in reference types) must be handled duringReferenceTypeHandler#activate(WriteContext)
- Specified by:
writeInstantiation
in interfaceInstantiatingTypeHandler
obj
- the object
-
instantiate
public java.lang.Object instantiate(ReadContext context)
- Specified by:
instantiate
in interfaceInstantiatingTypeHandler
-
create
protected abstract java.util.TreeSet create(java.util.Comparator comparator)
-
activate
public void activate(ReferenceActivationContext context)
Description copied from interface:ReferenceTypeHandler
gets called when an object is to be activated.- Specified by:
activate
in interfaceReferenceTypeHandler
-
write
public void write(WriteContext context, java.lang.Object obj)
Description copied from interface:TypeHandler4
gets called when an object is to be written to the database.- Specified by:
write
in interfaceTypeHandler4
obj
- the object
-
defragment
public void defragment(DefragmentContext context)
Description copied from interface:TypeHandler4
gets called when an object gets defragmented.- Specified by:
defragment
in interfaceTypeHandler4
-
delete
public void delete(DeleteContext context) throws Db4oIOException
Description copied from interface:TypeHandler4
gets called when an object gets deleted.- Specified by:
delete
in interfaceTypeHandler4
- Throws:
Db4oIOException
-
-