DefaultThreeWayConflictHandler
instead.@Deprecated public class DefaultConflictHandler extends java.lang.Object implements ConflictHandler
ConflictHandler
always returns the same resolution.
It can be used to implement default behaviour or as a base class for more specialised
implementations.PartialConflictHandler.Resolution
Modifier and Type | Field and Description |
---|---|
static ConflictHandler |
OURS
Deprecated.
A
ConflictHandler which always return ConflictHandler.Resolution.OURS . |
static ConflictHandler |
THEIRS
Deprecated.
A
ConflictHandler which always return ConflictHandler.Resolution.THEIRS . |
Constructor and Description |
---|
DefaultConflictHandler(PartialConflictHandler.Resolution resolution)
Deprecated.
Create a new
ConflictHandler which always returns resolution . |
Modifier and Type | Method and Description |
---|---|
PartialConflictHandler.Resolution |
addExistingNode(NodeBuilder parent,
java.lang.String name,
NodeState ours,
NodeState theirs)
Deprecated.
The node
ours has been added to parent which conflicts
with node theirs which has been added in the persistence store. |
PartialConflictHandler.Resolution |
addExistingProperty(NodeBuilder parent,
PropertyState ours,
PropertyState theirs)
Deprecated.
The property
ours has been added to parent which conflicts
with property theirs which has been added in the persistence store. |
PartialConflictHandler.Resolution |
changeChangedProperty(NodeBuilder parent,
PropertyState ours,
PropertyState theirs)
Deprecated.
The property
ours has been changed in parent while it was
also changed to a different value (theirs ) in the persistence store. |
PartialConflictHandler.Resolution |
changeDeletedNode(NodeBuilder parent,
java.lang.String name,
NodeState ours)
Deprecated.
The node
ours has been changed in parent while it was
removed in the persistence store. |
PartialConflictHandler.Resolution |
changeDeletedProperty(NodeBuilder parent,
PropertyState ours)
Deprecated.
The property
ours has been changed in parent while it was
removed in the persistence store. |
PartialConflictHandler.Resolution |
deleteChangedNode(NodeBuilder parent,
java.lang.String name,
NodeState theirs)
Deprecated.
The node
theirs changed in the persistence store while it has been
deleted locally. |
PartialConflictHandler.Resolution |
deleteChangedProperty(NodeBuilder parent,
PropertyState theirs)
Deprecated.
The property
theirs changed in the persistence store while it has been
deleted locally. |
PartialConflictHandler.Resolution |
deleteDeletedNode(NodeBuilder parent,
java.lang.String name)
Deprecated.
The node
name has been removed in parent while it was
also removed in the persistence store. |
PartialConflictHandler.Resolution |
deleteDeletedProperty(NodeBuilder parent,
PropertyState ours)
Deprecated.
The property
ours has been removed in parent while it was
also removed in the persistence store. |
public static final ConflictHandler OURS
ConflictHandler
which always return ConflictHandler.Resolution.OURS
.public static final ConflictHandler THEIRS
ConflictHandler
which always return ConflictHandler.Resolution.THEIRS
.public DefaultConflictHandler(PartialConflictHandler.Resolution resolution)
ConflictHandler
which always returns resolution
.resolution
- the resolution to return from all methods of this
ConflictHandler
instance.public PartialConflictHandler.Resolution addExistingProperty(NodeBuilder parent, PropertyState ours, PropertyState theirs)
ConflictHandler
ours
has been added to parent
which conflicts
with property theirs
which has been added in the persistence store.addExistingProperty
in interface ConflictHandler
addExistingProperty
in interface PartialConflictHandler
parent
- root of the conflictours
- our version of the propertytheirs
- their version of the propertyResolution
of the conflictpublic PartialConflictHandler.Resolution changeDeletedProperty(NodeBuilder parent, PropertyState ours)
ConflictHandler
ours
has been changed in parent
while it was
removed in the persistence store.changeDeletedProperty
in interface ConflictHandler
changeDeletedProperty
in interface PartialConflictHandler
parent
- root of the conflictours
- our version of the propertyResolution
of the conflictpublic PartialConflictHandler.Resolution changeChangedProperty(NodeBuilder parent, PropertyState ours, PropertyState theirs)
ConflictHandler
ours
has been changed in parent
while it was
also changed to a different value (theirs
) in the persistence store.changeChangedProperty
in interface ConflictHandler
changeChangedProperty
in interface PartialConflictHandler
parent
- root of the conflictours
- our version of the propertytheirs
- their version of the propertyResolution
of the conflictpublic PartialConflictHandler.Resolution deleteChangedProperty(NodeBuilder parent, PropertyState theirs)
ConflictHandler
theirs
changed in the persistence store while it has been
deleted locally.deleteChangedProperty
in interface ConflictHandler
deleteChangedProperty
in interface PartialConflictHandler
parent
- root of the conflicttheirs
- their version of the propertyResolution
of the conflictpublic PartialConflictHandler.Resolution deleteDeletedProperty(NodeBuilder parent, PropertyState ours)
ConflictHandler
ours
has been removed in parent
while it was
also removed in the persistence store.deleteDeletedProperty
in interface ConflictHandler
deleteDeletedProperty
in interface PartialConflictHandler
parent
- root of the conflictours
- our version of the propertyResolution
of the conflictpublic PartialConflictHandler.Resolution addExistingNode(NodeBuilder parent, java.lang.String name, NodeState ours, NodeState theirs)
ConflictHandler
ours
has been added to parent
which conflicts
with node theirs
which has been added in the persistence store.addExistingNode
in interface ConflictHandler
addExistingNode
in interface PartialConflictHandler
parent
- root of the conflictname
- name of the nodeours
- our version of the nodetheirs
- their version of the nodeResolution
of the conflictpublic PartialConflictHandler.Resolution changeDeletedNode(NodeBuilder parent, java.lang.String name, NodeState ours)
ConflictHandler
ours
has been changed in parent
while it was
removed in the persistence store.changeDeletedNode
in interface ConflictHandler
changeDeletedNode
in interface PartialConflictHandler
parent
- root of the conflictname
- name of the nodeours
- our version of the nodeResolution
of the conflictpublic PartialConflictHandler.Resolution deleteChangedNode(NodeBuilder parent, java.lang.String name, NodeState theirs)
ConflictHandler
theirs
changed in the persistence store while it has been
deleted locally.deleteChangedNode
in interface ConflictHandler
deleteChangedNode
in interface PartialConflictHandler
parent
- root of the conflictname
- name of the nodetheirs
- their version of the nodeResolution
of the conflictpublic PartialConflictHandler.Resolution deleteDeletedNode(NodeBuilder parent, java.lang.String name)
ConflictHandler
name
has been removed in parent
while it was
also removed in the persistence store.deleteDeletedNode
in interface ConflictHandler
deleteDeletedNode
in interface PartialConflictHandler
parent
- root of the conflictname
- name of the nodeResolution
of the conflictCopyright © 2010 - 2020 Adobe. All Rights Reserved