Table of Contents
DeltaXMLSync Concurrent Edit Ruleset
The following tables, show by example, how the concurrent edit ruleset operates on XML elements, attributes and text (PCDATA).
The general principles adopted are as follows:
- If one editor adds/changes content it appears in the result
- If one editor removes content it is removed from the result
- If both editors change the data differently or move/modify the same data then a conflict is reported.
The column headings correspond to the naming conventions in the ruleset and our command-line and online tools.
The dxce namespace prefix is used, without being properly defined, in order to save space; the corresponding namespace URI is: http://www.deltaxml.com/ns/concurrent-edit
1 Element Rules
base | edit1 | edit2 | result | |
|---|---|---|---|---|
Addition in edit1 | <e> <a/> <b/> </e> | <e> <a/> <b/> <c/> </e> | <e> <a/> <b/> </e> | <e> <a/> <b/> <c/> </e> |
Addition in edit2 | <e> <a/> <b/> </e> | <e> <a/> <b/> </e> | <e> <a/> <b/> <c/> </e> | <e> <a/> <b/> <c/> </e> |
Addition in both, same content | <e> <a/> <b/> </e> | <e> <a/> <b/> <c/> </e> | <e> <a/> <b/> <c/> </e> | <e> <a/> <b/> <c/> </e> |
Addition in both, different content | <e> <a/> <b/> </e> | <e> <a/> <b/> <c/> </e> | <e> <a/> <b/> <d/> </e> | <e> <a/> <b/> <c/> <d/> </e> |
Deletion in edit1 | <e> <a/> <b/> </e> | <e> <a/> </e> | <e> <a/> <b/> </e> | <e> <a/> </e> |
Deletion in edit2 | <e> <a/> <b/> </e> | <e> <a/> <b/> </e> | <e> <a/> </e> | <e> <a/> </e> |
Deletion in both | <e> <a/> <b/> </e> | <e> <a/> </e> | <e> <a/> </e> | <e> <a/> </e> |
Change in edit1 | <e> <a/> <b/> </e> | <e> <a/> <b> <b1/> </b> </e> | <e> <a/> <b/> </e> | <e> <a/> <b> <b1/> </b> </e> |
Change in edit2 | <e> <a/> <b/> </e> | <e> <a/> <b/> </e> | <e> <a/> <b> <b2/> </b> </e> | <e> <a/> <b> <b2/> </b> </e> |
Change in both, same content | <e> <a/> <b/> </e> | <e> <a/> <b> <b3/> </b> </e> | <e> <a/> <b> <b3/> </b> </e> | <e> <a/> <b> <b3/> </b> </e> |
Change in both, different content | <e> <a/> <b/> </e> | <e> <a/> <b> <b1/> </b> </e> | <e> <a/> <b> <b1/> </b> </e> | <e> <a/> <b> <b1/> <b2/> </b> </e> |
Change in edit1, deletion in edit2 | <e> <a/> <b/> </e> | <e> <a/> <b> <b1/> </b> </e> | <e> <a/> </e> | <e> <a/> <dxce:elementConflict dxce:type="modified-edit1-deleted-edit2"> <dxce:base> <b/> </dxce:base> <dxce:edit1> <b> <b1/> </b> </dxce:edit1> </dxce:elementConflict> </e> |
Change in edit2, deletion in edit1 | <e> <a/> <b/> </e> | <e> <a/> </e> | <e> <a/> <b> <b2/> </b> </e> | <e> <a/> <dxce:elementConflict dxce:type="deleted-edit1-modified-edit2"> <dxce:base> <b/> </dxce:base> <dxce:edit2> <b> <b2/> </b> </dxce:edit2> </dxce:elementConflict> </e> |
2 PCData Rules
base | edit1 | edit2 | result | |
|---|---|---|---|---|
Addition in edit1 | <e></e> | <e>1</e> | <e></e> | <e>1</e> |
Addition in edit2 | <e></e> | <e></e> | <e>2</e> | <e>2</e> |
Addition in both, same text | <e></e> | <e>3</e> | <e>3</e> | <e>3</e> |
Addition in both, different text | <e></e> | <e>1</e> | <e>2</e> | <e> |
Deletion in edit1 | <e>3</e> | <e></e> | <e>3</e> | <e></e> |
Deletion in edit2 | <e>3</e> | <e>3</e> | <e></e> | <e></e> |
Deletion in both | <e>3</e> | <e></e> | <e></e> | <e></e> |
Contents change in edit1 | <e>3</e> | <e>1</e> | <e>3</e> | <e>1</e> |
Contents change in edit2 | <e>3</e> | <e>3</e> | <e>2</e> | <e>2</e> |
Contents change in both, | <e>3</e> | <e>4</e> | <e>4</e> | <e>4</e> |
Contents change in both, | <e>3</e> | <e>1</e> | <e>2</e> | <e> |
Contents change in edit1, | <e>3</e> | <e>1</e> | <e></e> | <e> |
Contents change in edit2, | <e>3</e> | <e></e> | <e>2</e> | <e> |
3 Attribute Rules
base | edit1 | edit2 | result | |
|---|---|---|---|---|
Attribute addition in edit1 | <e/> | <e a="1"/> | <e/> | <e a="1"/> |
Attribute addition in edit2 | <e/> | <e/> | <e a="1"/> | <e a="2"/> |
Addition in both, same values | <e/> | <e a="3"/> | <e a="3"/> | <e a="3"/> |
Addition in both, different values | <e/> | <e a="1"/> | <e a="2"/> | <e> |
Attribute deletion in edit1 | <e a="3"/> | <e/> | <e a="3"/> | <e/> |
Attribute deletion in edit2 | <e a="3"/> | <e a="3"/> | <e/> | <e/> |
Attribute deletion in both | <e a="3"/> | <e/> | <e/> | <e/> |
Value changes in edit1 | <e a="3"/> | <e a="1"/> | <e a="3"/> | <e a="1"/> |
Value changes in edit2 | <e a="3"/> | <e a="3"/> | <e a="2"/> | <e a="2"/> |
Value changes in both, same value | <e a="3"/> | <e a="4"/> | <e a="4"/> | <e a="4"/> |
Value changes in both, different values | <e a="3"/> | <e a="1"/> | <e a="2"/> | <e> |
Value change in edit1, attribute deletion in edit2 | <e a="3"/> | <e a="1"/> | <e/> | <e> |
Value change in edit2, attribute deletion in edit1 | <e a="3"/> | <e/> | <e a="2"/> | <e> |
