Oracle Fusion Middleware Java API Reference for Oracle Extension SDK Reference
11g Release 1 (11.1.1)

E13403-04

oracle.javatools.db
Class AbstractBuildableObject

java.lang.Object
  extended by oracle.javatools.db.AbstractDBObject
      extended by oracle.javatools.db.AbstractBuildableObject
All Implemented Interfaces:
DBObject, SystemObject, Copyable, DynamicPropertySet
Direct Known Subclasses:
AbstractSchemaObject, Schema, Tablespace

public abstract class AbstractBuildableObject
extends AbstractDBObject
implements SystemObject

Provides methods for lazy loading and building AbstractDBObjects. This has been abstracted from AbstractSchemaObject.

Since:
11.1.1.2.0

Nested Class Summary
 
Nested classes/interfaces inherited from class oracle.javatools.db.AbstractDBObject
AbstractDBObject.ChildSupport
 
Field Summary
 
Fields inherited from interface oracle.javatools.db.DBObject
COMMENT
 
Constructor Summary
  AbstractBuildableObject()
           
protected AbstractBuildableObject(java.lang.String name, DBObjectID id)
          Constructs a new instance with the specified name and id.
 
Method Summary
 void addObjectListener(DBObjectListener list)
          Attaches a listener to this object to listen for change events.
protected  void checkInit()
          Checks that the whole object is initialized (built).
protected  void checkInit(java.lang.String key)
          Checking initialisation with no key, is the came as initializing the whole object, and is what checkInit() does.
protected  void checkInitEx(java.lang.String key)
           
protected  void copyToImpl(AbstractBuildableObject copy, DBObject copyParent, IDPolicy idPolicy)
           
protected  boolean equalsImpl(AbstractBuildableObject target)
           
 void fireObjectUpdated(DBObjectChange change)
          Notifies any registered listeners of the change to this object.
protected  void getOwnedObjectsImpl(java.util.Collection<DBObject> c, java.lang.String... types)
          Implementation first checks that the object has been built - then returns the collection from suprt.getOwnedObjectsImpl().
 java.util.Map getProperties()
          Returns null if no properties are set.
 java.lang.Object getProperty(java.lang.String key)
          Retrieves the value associated with a property.
 java.lang.Object getProperty(java.lang.String key, java.lang.Object defaultValue)
          Retrieves the value associated with a property.
protected  void getReferenceIDsImpl(java.util.Collection<DBObjectID> refs)
          Implementation first checks that the object has been built - then returns the collection from suprt.getReferenceIDsImpl().
protected  boolean needsInitialization()
           
 void removeObjectListener(DBObjectListener list)
          Removes the given listener from the list of registered listeners for this class.
 void setProperties(java.util.Map properties)
          Sets the properties of this object to be those in the given Map.
 void setProperty(java.lang.String key, java.lang.Object value)
          Sets the value for a property.
 
Methods inherited from class oracle.javatools.db.AbstractDBObject
changeParent, compareToImpl, copyObject, copyTo, copyTo, copyTo, copyTo, copyToImpl, equalsImpl, findOwnedObject, findOwnedObject, findOwnedObject, getChildSupport, getID, getName, getOwnedObjects, getOwnedObjects, getReferenceIDs, hashCode, includeOwnedObject, includesType, includesType, removeThisAsParent, replaceReferenceIDs, setID, setName, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface oracle.javatools.db.DBObject
copyTo, copyTo, copyTo, findOwnedObject, findOwnedObject, getID, getName, getOwnedObjects, getOwnedObjects, getParent, getReferenceIDs, getType, replaceReferenceIDs, setID, setName
 

Constructor Detail

AbstractBuildableObject

public AbstractBuildableObject()

AbstractBuildableObject

protected AbstractBuildableObject(java.lang.String name,
                                  DBObjectID id)
Constructs a new instance with the specified name and id.

Parameters:
name - a string representing the name of this object.
id - the id for this object.
Method Detail

needsInitialization

protected boolean needsInitialization()

checkInit

protected void checkInit(java.lang.String key)
Checking initialisation with no key, is the came as initializing the whole object, and is what checkInit() does.


checkInitEx

protected void checkInitEx(java.lang.String key)
                    throws DBException
Throws:
DBException

checkInit

protected void checkInit()
Checks that the whole object is initialized (built).


getProperties

public java.util.Map getProperties()
Description copied from class: AbstractDBObject
Returns null if no properties are set.

Specified by:
getProperties in interface DynamicPropertySet
Overrides:
getProperties in class AbstractDBObject

getProperty

public java.lang.Object getProperty(java.lang.String key)
Description copied from interface: DynamicPropertySet
Retrieves the value associated with a property.

Specified by:
getProperty in interface DynamicPropertySet
Overrides:
getProperty in class AbstractDBObject
Parameters:
key - the property key for which a value is desired. exists.
Returns:
the value of the requested property, or a null value if the property does not exist or is not set.

getProperty

public java.lang.Object getProperty(java.lang.String key,
                                    java.lang.Object defaultValue)
Description copied from interface: DynamicPropertySet
Retrieves the value associated with a property. If no value exists for the requested property, the specified default value is returned.

Specified by:
getProperty in interface DynamicPropertySet
Overrides:
getProperty in class AbstractDBObject
Parameters:
key - the property key for which a value is desired.
defaultValue - the value to return if no value currently exists.
Returns:
the value of the requested property, or the default value if the property does not exist.

setProperty

public void setProperty(java.lang.String key,
                        java.lang.Object value)
Description copied from interface: DynamicPropertySet
Sets the value for a property. Setting a value to null removes that property.

Specified by:
setProperty in interface DynamicPropertySet
Overrides:
setProperty in class AbstractDBObject
Parameters:
key - the property key to set
value - the value to set

setProperties

public void setProperties(java.util.Map properties)
Description copied from class: AbstractDBObject
Sets the properties of this object to be those in the given Map. The keys in the map must be Strings.

Specified by:
setProperties in interface DynamicPropertySet
Overrides:
setProperties in class AbstractDBObject

getOwnedObjectsImpl

protected void getOwnedObjectsImpl(java.util.Collection<DBObject> c,
                                   java.lang.String... types)
Implementation first checks that the object has been built - then returns the collection from suprt.getOwnedObjectsImpl(). All overrides must call this first to ensure the object has been built.

Overrides:
getOwnedObjectsImpl in class AbstractDBObject
Parameters:
c - a Collection of the apppropriate children.
types - a vararg of the type(s) to search for
See Also:
AbstractDBObject.includesType(java.lang.String, java.lang.String...)

getReferenceIDsImpl

protected void getReferenceIDsImpl(java.util.Collection<DBObjectID> refs)
Implementation first checks that the object has been built - then returns the collection from suprt.getReferenceIDsImpl(). All overrides must call this first to ensure the object has been built.

Overrides:
getReferenceIDsImpl in class AbstractDBObject
Parameters:
refs - the collection of ids this object references

copyToImpl

protected void copyToImpl(AbstractBuildableObject copy,
                          DBObject copyParent,
                          IDPolicy idPolicy)

equalsImpl

protected boolean equalsImpl(AbstractBuildableObject target)

fireObjectUpdated

public final void fireObjectUpdated(DBObjectChange change)
Description copied from interface: SystemObject
Notifies any registered listeners of the change to this object.

Specified by:
fireObjectUpdated in interface SystemObject

removeObjectListener

public final void removeObjectListener(DBObjectListener list)
Description copied from interface: SystemObject
Removes the given listener from the list of registered listeners for this class.

Specified by:
removeObjectListener in interface SystemObject
See Also:
DBObjectListener

addObjectListener

public final void addObjectListener(DBObjectListener list)
Description copied from interface: SystemObject
Attaches a listener to this object to listen for change events.

Specified by:
addObjectListener in interface SystemObject
See Also:
DBObjectListener

Oracle Fusion Middleware Java API Reference for Oracle Extension SDK Reference
11g Release 1 (11.1.1)

E13403-04

Copyright © 1997, 2010, Oracle. All rights reserved.