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

E13403-04

oracle.javatools.db
Class DBObjectChange

java.lang.Object
  extended by oracle.javatools.db.DBObjectChange

public class DBObjectChange
extends java.lang.Object

A DBObjectChange is used to notify of changes to a DBObject. It is passed to any appropriate listeners when the provider creates, updates or removes objects. A DBObjectChange is not limited to one type of change, it can contain multiple changes (e.g. children removed as well as children added). A DBObjectChange can include changes to child objects as well through the getOwnedObjectsChanged() method.

Since:
10.1.3

Field Summary
static java.lang.String NAME_PROPERTY
          Key for the property map to see if an object's name has been changed.
 
Constructor Summary
protected DBObjectChange(DBObject obj)
           
 
Method Summary
static void fireChildrenAdded(SystemObject obj, java.util.List added)
           
static void fireChildrenRemoved(SystemObject obj, java.util.List removed)
           
static void fireChildUpdated(SystemObject obj, DBObject child)
           
static void fireObjectUpdated(SystemObject obj)
          Fires an empty change message on the given object.
static void fireObjectUpdated(SystemObject obj, java.util.List<DBObject> added, java.util.List<DBObject> removed, java.util.Map<java.lang.String,java.beans.PropertyChangeEvent> props)
           
static void firePropertiesChanged(SystemObject obj, java.util.Map<java.lang.String,java.beans.PropertyChangeEvent> props)
           
static void firePropertyChanged(SystemObject obj, java.beans.PropertyChangeEvent... pces)
           
static void fireSchemaUpdated(AbstractDBObjectProvider pro, Schema schema, java.util.Map<java.lang.String,java.beans.PropertyChangeEvent> props)
           
 DBObject getDBObject()
          Gets the object this change has been on.
 java.util.List<DBObject> getOwnedObjectsAdded()
          Returns any owned objects added to the ListenableObject as a result of the change.
 java.util.Map<DBObject,DBObjectChange> getOwnedObjectsChanged()
          Returns any changes that have happened to any owned objects.
 java.util.List<DBObject> getOwnedObjectsRemoved()
          Returns any owned objects removed from the ListenableObject as a result of the change.
 java.util.Map<java.lang.String,java.beans.PropertyChangeEvent> getPropertiesChanged()
          Returns any properties changed on the ListenableObject as a result of the change.
 boolean hasNameChanged()
          Convinience method to identify whether the "name" property has been changed - looks in the properties changed map for the property as a key.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

NAME_PROPERTY

public static final java.lang.String NAME_PROPERTY
Key for the property map to see if an object's name has been changed.

See Also:
hasNameChanged(), Constant Field Values
Constructor Detail

DBObjectChange

protected DBObjectChange(DBObject obj)
Method Detail

getDBObject

public DBObject getDBObject()
Gets the object this change has been on.


getOwnedObjectsAdded

public java.util.List<DBObject> getOwnedObjectsAdded()
Returns any owned objects added to the ListenableObject as a result of the change.


getOwnedObjectsRemoved

public java.util.List<DBObject> getOwnedObjectsRemoved()
Returns any owned objects removed from the ListenableObject as a result of the change.


getPropertiesChanged

public java.util.Map<java.lang.String,java.beans.PropertyChangeEvent> getPropertiesChanged()
Returns any properties changed on the ListenableObject as a result of the change. The key is the property name and the value a PropertyChangeEvent.


getOwnedObjectsChanged

public java.util.Map<DBObject,DBObjectChange> getOwnedObjectsChanged()
Returns any changes that have happened to any owned objects. The key is the owned object and the value a DBObjectChange.


hasNameChanged

public boolean hasNameChanged()
Convinience method to identify whether the "name" property has been changed - looks in the properties changed map for the property as a key.

See Also:
NAME_PROPERTY

fireObjectUpdated

public static void fireObjectUpdated(SystemObject obj)
Fires an empty change message on the given object. Where possible use a more specific message

See Also:
fireChildrenAdded(oracle.javatools.db.SystemObject, java.util.List), fireChildrenRemoved(oracle.javatools.db.SystemObject, java.util.List), firePropertiesChanged(oracle.javatools.db.SystemObject, java.util.Map)

fireChildrenAdded

public static void fireChildrenAdded(SystemObject obj,
                                     java.util.List added)

fireChildrenRemoved

public static void fireChildrenRemoved(SystemObject obj,
                                       java.util.List removed)

firePropertyChanged

public static void firePropertyChanged(SystemObject obj,
                                       java.beans.PropertyChangeEvent... pces)

firePropertiesChanged

public static void firePropertiesChanged(SystemObject obj,
                                         java.util.Map<java.lang.String,java.beans.PropertyChangeEvent> props)

fireObjectUpdated

public static void fireObjectUpdated(SystemObject obj,
                                     java.util.List<DBObject> added,
                                     java.util.List<DBObject> removed,
                                     java.util.Map<java.lang.String,java.beans.PropertyChangeEvent> props)

fireChildUpdated

public static void fireChildUpdated(SystemObject obj,
                                    DBObject child)

fireSchemaUpdated

public static void fireSchemaUpdated(AbstractDBObjectProvider pro,
                                     Schema schema,
                                     java.util.Map<java.lang.String,java.beans.PropertyChangeEvent> props)

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.