|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.eclipse.emf.ecore.change.util.ListDifferenceAnalyzer
public class ListDifferenceAnalyzer
Abstract class implementing the methods required to compute differences between
lists. The differences are described by ListChange objects.
| Constructor Summary | |
|---|---|
ListDifferenceAnalyzer()
|
|
| Method Summary | |
|---|---|
EList<ListChange> |
analyzeLists(EList<?> oldList,
EList<?> newList)
Analyzes the differences between two lists, returning the list changes
that describe how the newList could be changed to the contents of
oldList. |
void |
analyzeLists(EList<java.lang.Object> oldList,
EList<?> newList,
EList<ListChange> listChanges)
Analyzes the differences between two lists, adding new list changes to the
specified listChanges. |
protected void |
createAddListChange(EList<java.lang.Object> oldList,
EList<ListChange> listChanges,
java.lang.Object newObject,
int index)
Convenience method added to allow subclasses to modify the default implementation for the scenario in which an element was added to the monitored list. |
protected ListChange |
createListChange(EList<ListChange> listChanges,
ChangeKind kind,
int index)
Creates a ListChange, initialzes the main attributes, and adds it to the specified listChanges. |
protected void |
createListChanges(EList<java.lang.Object> oldList,
EList<?> newList,
EList<ListChange> listChanges)
|
protected void |
createMoveListChange(EList<?> oldList,
EList<ListChange> listChanges,
java.lang.Object newObject,
int index,
int toIndex)
Convenience method added to allow subclasses to modify the default implementation for the scenario in which an element was moved in the monitored list. |
protected void |
createRemoveListChange(EList<?> oldList,
EList<ListChange> listChanges,
java.lang.Object newObject,
int index)
Convenience method added to allow subclasses to modify the default implementation for the scenario in which an element was removed from the monitored list. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ListDifferenceAnalyzer()
| Method Detail |
|---|
public EList<ListChange> analyzeLists(EList<?> oldList,
EList<?> newList)
list changes
that describe how the newList could be changed to the contents of
oldList. The lists are not modified by this method.
oldList - newList -
ListChange
public void analyzeLists(EList<java.lang.Object> oldList,
EList<?> newList,
EList<ListChange> listChanges)
Analyzes the differences between two lists, adding new list changes to the
specified listChanges. The list changes describe how the newList
should be manipulated in order to have the same contents of oldList
This methods changes the contents of oldList
oldList - newList - listChanges -
protected void createListChanges(EList<java.lang.Object> oldList,
EList<?> newList,
EList<ListChange> listChanges)
analyzeLists(EList, EList, EList)
protected void createAddListChange(EList<java.lang.Object> oldList,
EList<ListChange> listChanges,
java.lang.Object newObject,
int index)
createListChanges(EList, EList, EList)
protected void createRemoveListChange(EList<?> oldList,
EList<ListChange> listChanges,
java.lang.Object newObject,
int index)
createListChanges(EList, EList, EList)
protected void createMoveListChange(EList<?> oldList,
EList<ListChange> listChanges,
java.lang.Object newObject,
int index,
int toIndex)
createListChanges(EList, EList, EList)
protected ListChange createListChange(EList<ListChange> listChanges,
ChangeKind kind,
int index)
listChanges - kind - index -
|
Copyright 2001-2006 IBM Corporation and others. All Rights Reserved. |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||