Class SCOProcessor

  extended bycom.triactive.jdo.sco.SCOProcessor
Direct Known Subclasses:
SCOProcessor.DateProcessor, SCOProcessor.MapProcessor, SCOProcessor.SetProcessor, SCOProcessor.SqlDateProcessor, SCOProcessor.SqlTimestampProcessor

public abstract class SCOProcessor
extends java.lang.Object

An object that helps manage SCO fields of a particular declared type. Currently, an SCO processor's only function is to serve as a factory for SCO insatnces.

Mike Martin

Nested Class Summary
static class SCOProcessor.DateProcessor
          The SCO processor for java.util.Date fields.
static class SCOProcessor.HashMapProcessor
          The SCO processor for java.util.HashMap fields.
static class SCOProcessor.HashSetProcessor
          The SCO processor for java.util.HashSet fields.
static class SCOProcessor.HashtableProcessor
          The SCO processor for java.util.Hashtable fields.
static class SCOProcessor.MapProcessor
          An SCO processor for Map fields.
static class SCOProcessor.SetProcessor
          An SCO processor for Set fields.
static class SCOProcessor.SqlDateProcessor
          The SCO processor for java.sql.Date fields.
static class SCOProcessor.SqlTimestampProcessor
          The SCO processor for java.sql.Timestamp fields.
Constructor Summary
Method Summary
static SCOProcessor forFieldType(java.lang.Class c)
          Returns the SCO processor for fields of the given type.
static boolean isSecondClassMutableType(java.lang.Class c)
          Tests whether a given type represents a supported second-class mutable type.
abstract  SCO newSCOInstance(java.lang.Object owner, java.lang.String fieldName, java.lang.Object value)
          Returns a new SCO instance.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail


public SCOProcessor()
Method Detail


public static boolean isSecondClassMutableType(java.lang.Class c)
Tests whether a given type represents a supported second-class mutable type.

c - The class to be tested.
true if fields declared as type c are supported as second-class mutable objects, false otherwise.


public static SCOProcessor forFieldType(java.lang.Class c)
Returns the SCO processor for fields of the given type.

c - The type of field.
The corresponding SCO processor.


public abstract SCO newSCOInstance(java.lang.Object owner,
                                   java.lang.String fieldName,
                                   java.lang.Object value)
Returns a new SCO instance. The returned instance is owned by the specified owner but has not been assigned to the corresponding field.

owner - The first-class object that will own the new second-class object.
fieldName - The name of the field in the owning object.
value - The initial value of the new object.
A new SCO instance.

Copyright 2001-2007 The TJDO Project All Rights Reserved.