Class MetisListChange<T extends MetisDataItem.MetisDataIndexedItem>
java.lang.Object
io.github.tonywasher.joceanus.metis.list.MetisListChange<T>
- Type Parameters:
T- the item type
Metis VersionedList Event.
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedMetisListChange(MetisListKey pItemType, MetisListEvent pEventType) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionObtain the iterator for added items.Obtain the iterator for changed items.Obtain the iterator for added items.Obtain the event type.Obtain the item type.intObtain the version.booleanHave we got any added items?booleanHave we got any changed items?booleanHave we got any deleted items?booleanisEmpty()Is this an empty changeSet?protected voidregisterAdded(T pItem) Register added item.protected voidregisterChanged(T pItem) Register changed item.protected voidregisterDeleted(T pItem) Register deleted item.voidsetVersion(int pVersion) Set the version.
-
Constructor Details
-
MetisListChange
Constructor.- Parameters:
pItemType- the item typepEventType- the event type
-
-
Method Details
-
getItemType
Obtain the item type.- Returns:
- the item type
-
getEventType
Obtain the event type.- Returns:
- the event type
-
setVersion
public void setVersion(int pVersion) Set the version.- Parameters:
pVersion- the version
-
getVersion
public int getVersion()Obtain the version.- Returns:
- the version
-
isEmpty
public boolean isEmpty()Is this an empty changeSet?- Returns:
- true/false
-
haveAdded
public boolean haveAdded()Have we got any added items?- Returns:
- true/false
-
haveChanged
public boolean haveChanged()Have we got any changed items?- Returns:
- true/false
-
haveDeleted
public boolean haveDeleted()Have we got any deleted items?- Returns:
- true/false
-
addedIterator
Obtain the iterator for added items.- Returns:
- the iterator
-
changedIterator
Obtain the iterator for changed items.- Returns:
- the iterator
-
deletedIterator
Obtain the iterator for added items.- Returns:
- the iterator
-
registerAdded
Register added item.- Parameters:
pItem- the item that was added
-
registerChanged
Register changed item.- Parameters:
pItem- the item that was changed
-
registerDeleted
Register deleted item.- Parameters:
pItem- the item that was deleted
-