139
which “promotes loose coupling by keeping objects from referring to each other explicitly.”
(Gamma, Helm et al. 1995), p. 273.
7.1.1 The local store
The local store, like Gaul, can be divided into three parts, the public interface (an in-
stance of the Façade pattern (Gamma, Helm et al. 1995)), the Palimpsest data store itself,
and the policy manager. The data store was discussed in Chapter 6, and despite significant
internal complexity it presents a very simple interface. Figure 7.2 show the most ciritical
operations that a local store needs to support. All of these operations are suitable for direct
use by an application that is willing to manage its own change conflicts directly, or to take
advantage of built-in resolution strategies. The functions listed are self explanatory, for the
most part. We will see later that most applications will probably use a wrapped interface that
is simpler and may provide better performance in highly interactive applications.
Item [] getSegmentAt(Address a, ChangeSetID set)
Item [] contentsOf(Address a, ChangeSetID set)
Item [] contentsOf(Address start, Address end, ChangeSetID set)
SegmentIterator enumerateContents(Address a, ChangeSetID set)
ConflictSet addChange(ChangeID id, ChangeSetID set)
void removeChangeFromSet(ChangeID id, ChangeSetID set)
ChangeID insert(Item [], Address dest)
ChangeID delete(Address start, Address end)
ChangeID copy(Address start, Address end, Address dest)
ChangeID move(Address start, Address end, Address dest)
void setResolveConflicts(Boolean flag)
ChangeSetIterator getChangeSets()
ChangeIterator getChanges(ChangeSetID set)
CorrelationMap compare(ChangeSetID version1, ChangeSetID version2)
F F F F iii ig g g gu u u ur r r re e e e 7777....2222:::: CCCCoooommmmmmmmoooonnnn ooooppppeeeerrrraaaattttiiiioooonnnnssss ffffoooorrrr tttthhhheeee ddddaaaattttaaaa ssssttttoooorrrreeee
7.1.2 The policy manager
The policy manager manages application conflicts, as well as replication and event propa-
gation. The policy manager receives every change from the local application as well as from
which “promotes loose coupling by keeping objects from referring to each other explicitly.”
(Gamma, Helm et al. 1995), p. 273.
7.1.1 The local store
The local store, like Gaul, can be divided into three parts, the public interface (an in-
stance of the Façade pattern (Gamma, Helm et al. 1995)), the Palimpsest data store itself,
and the policy manager. The data store was discussed in Chapter 6, and despite significant
internal complexity it presents a very simple interface. Figure 7.2 show the most ciritical
operations that a local store needs to support. All of these operations are suitable for direct
use by an application that is willing to manage its own change conflicts directly, or to take
advantage of built-in resolution strategies. The functions listed are self explanatory, for the
most part. We will see later that most applications will probably use a wrapped interface that
is simpler and may provide better performance in highly interactive applications.
Item [] getSegmentAt(Address a, ChangeSetID set)
Item [] contentsOf(Address a, ChangeSetID set)
Item [] contentsOf(Address start, Address end, ChangeSetID set)
SegmentIterator enumerateContents(Address a, ChangeSetID set)
ConflictSet addChange(ChangeID id, ChangeSetID set)
void removeChangeFromSet(ChangeID id, ChangeSetID set)
ChangeID insert(Item [], Address dest)
ChangeID delete(Address start, Address end)
ChangeID copy(Address start, Address end, Address dest)
ChangeID move(Address start, Address end, Address dest)
void setResolveConflicts(Boolean flag)
ChangeSetIterator getChangeSets()
ChangeIterator getChanges(ChangeSetID set)
CorrelationMap compare(ChangeSetID version1, ChangeSetID version2)
F F F F iii ig g g gu u u ur r r re e e e 7777....2222:::: CCCCoooommmmmmmmoooonnnn ooooppppeeeerrrraaaattttiiiioooonnnnssss ffffoooorrrr tttthhhheeee ddddaaaattttaaaa ssssttttoooorrrreeee
7.1.2 The policy manager
The policy manager manages application conflicts, as well as replication and event propa-
gation. The policy manager receives every change from the local application as well as from