Package com.vaadin.flow.internal.change
Class ListRemoveChange<T extends Serializable>
java.lang.Object
com.vaadin.flow.internal.change.NodeChange
com.vaadin.flow.internal.change.NodeFeatureChange
com.vaadin.flow.internal.change.AbstractListChange<T>
com.vaadin.flow.internal.change.ListRemoveChange<T>
- Type Parameters:
T- the type of the items in the node list
- All Implemented Interfaces:
Serializable
Change describing a remove operation in a
list node feature.
For internal use only. May be renamed or removed in a future release.
- Since:
- 1.0
- Author:
- Vaadin Ltd
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionListRemoveChange(NodeList<T> list, int index, T removedItem) Creates a new list remove change. -
Method Summary
Modifier and TypeMethodDescriptioncopy(int indx) Gets a copy of the change with the same data exceptindex.Gets the removed item.protected voidpopulateJson(tools.jackson.databind.node.ObjectNode json, ConstantPool constantPool) Overridden by subclasses to populate a JSON object when serializing.Methods inherited from class com.vaadin.flow.internal.change.AbstractListChange
getIndex, getNodeList, setIndexMethods inherited from class com.vaadin.flow.internal.change.NodeFeatureChange
getFeatureMethods inherited from class com.vaadin.flow.internal.change.NodeChange
getNode, toJson
-
Constructor Details
-
ListRemoveChange
Creates a new list remove change.- Parameters:
list- the changed listindex- the index of the remove operationremovedItem- a removed item
-
-
Method Details
-
getRemovedItem
Gets the removed item.This method is public only for testing reasons.
- Returns:
- the removed item
-
copy
Description copied from class:AbstractListChangeGets a copy of the change with the same data exceptindex.- Specified by:
copyin classAbstractListChange<T extends Serializable>- Parameters:
indx- the new index of the change- Returns:
- a copy of the change based on new index
-
populateJson
Description copied from class:NodeChangeOverridden by subclasses to populate a JSON object when serializing.- Overrides:
populateJsonin classNodeFeatureChange- Parameters:
json- the json object to populateconstantPool- the constant pool to use for serializing constant pool references
-