oracle.sysman.dbTarget.db.changemgr.emo.docaccess
Class ApplyDiffListenerImpl
java.lang.Object
oracle.sysman.dbTarget.db.changemgr.emo.docaccess.ApplyDiffListenerImpl
- All Implemented Interfaces:
- ApplyDiffListener
public class ApplyDiffListenerImpl
- extends java.lang.Object
- implements ApplyDiffListener
This class is an implementation of the ApplyDiffListener
interface that clients can use to monitor and control the action
of the XMLAccessor.applyDiffs()
method.
Method Summary |
void |
applyDiffResult(ApplyOneDiffResult odr,
XMLAccessor xa)
Called by the
XMLAccessor.applyDiffs() method
for each difference that is applied to the target database object. |
boolean |
getAction(int conflictType,
int diffType)
Returns the current conflict resolution action for the
specified conflict type and difference type. |
void |
setAction(int conflictType,
int diffType,
boolean action)
Sets the desired conflict resolution action for the
specified conflict type and difference type. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ApplyDiffListenerImpl
public ApplyDiffListenerImpl()
applyDiffResult
public void applyDiffResult(ApplyOneDiffResult odr,
XMLAccessor xa)
- Called by the
XMLAccessor.applyDiffs()
method
for each difference that is applied to the target database object.
The implementation may examine the ApplyOneDiffResult
object to determine whether any conflicts have been detected,
and override the default conflict resolution action by
calling the ApplyOneDiffResult.setDoChange(boolean)
method.
- Specified by:
applyDiffResult
in interface ApplyDiffListener
- Parameters:
odr
- an ApplyOneDiffResult
object containing information about
the result of applying a difference
to a target database object.xa
- the XMLAccessor instance that
represents the object to which
the diff is applied
getAction
public boolean getAction(int conflictType,
int diffType)
- Returns the current conflict resolution action for the
specified conflict type and difference type.
- Parameters:
conflictType
- one of the conflict types defined
in the ApplyDiffListener
interface.diffType
- one of the difference types defined
in the ApplyDiffListener
interface.
- Returns:
- true if the conflict should resolved
in favor of the change, false if
in favor of the status quo.
setAction
public void setAction(int conflictType,
int diffType,
boolean action)
- Sets the desired conflict resolution action for the
specified conflict type and difference type. (Note that the
difference type is ignored in this implementation.)
- Parameters:
conflictType
- one of the conflict types defined
in the ApplyDiffListener
interface.diffType
- one of the difference types defined
in the ApplyDiffListener
interface.action
- true to resolve the conflict
in favor of the change, false to resolve
it in favor of the status quo.