A wrapper class for adding external ordering to containers not
implementing the
com.itmill.toolkit.data.Container.Ordered
interface.
If the wrapped container is changed directly (that is, not through
the wrapper), the ordering must be updated with the
updateOrderWrapper()
method.
3.0
Inheritance Path. java.lang.Object-> com.itmill.toolkit.data.util.ContainerOrderedWrapper
Parameters
toBeWrapped
the container whose contents need to be ordered
Constructs a new ordered wrapper for an existing Container. Works even if the to-be-wrapped container already implements the Container.Ordered interface.
Parameters
propertyId
ID of the new Property
type
Data type of the new Property
defaultValue
The value all created Properties are initialized to
true
if the operation succeeded,
false
if not
Adds a new Property to all Items in the Container.
Parameters
the autogenerated ID of the new Item or
null
if the operation failed
Creates a new Item into the Container, assigns it an automatic ID, and adds it to the ordering.
Parameters
the added Item or
null
if the operation failed
Adds a new Item by its ID to the underlying container and to the ordering.
Parameters
previousItemId
Id of the previous item in ordered container.
Returns item id the the created new item or null if the operation fails.
addItemAfter(java.lang.Object)
Add new item after the given item.
Adding an item after null item adds the item as first item of the ordered container.
Parameters
previousItemId
Id of the previous item in ordered container.
newItemId
Id of the new item to be added.
Returns new item or null if the operation fails.
Add new item after the given item.
Adding an item after null item adds the item as first item of the ordered container.
Parameters
listener
listener to be added
Adds a Item set change listener for the object.
Parameters
listener
The new Listener to be registered
Registers a new Property set change listener for this Container.
Parameters
ID of the first Item in the Container
Gets the ID of the first Item in the Container.
Parameters
itemId
ID of an Item in the Container
true
if the Item is first in the Container,
false
if not
Tests if the Item corresponding to the given Item ID is the first Item in the Container.
Parameters
true
if the Item is last in the Container,
false
if not
Tests if the Item corresponding to the given Item ID is the last Item in the Container.
Parameters
ID of the last Item in the Container
Gets the ID of the last Item in the Container..
Parameters
itemId
ID of an Item in the Container
ID of the next Item or
null
Gets the ID of the Item following the Item that corresponds to
itemId
. If the given Item is the last or not found in
the Container,
null
is returned.
Parameters
itemId
ID of an Item in the Container
ID of the previous Item or
null
Gets the ID of the Item preceding the Item that corresponds to
itemId
. If the given Item is the first or not found
in the Container,
null
is returned.
Parameters
true
if the operation succeeded,
false
if not
Removes all items from the underlying container and from the ordering.
Parameters
propertyId
ID of the Property to remove
true
if the operation succeeded,
false
if not
Removes the specified Property from the underlying container and from the ordering. Note that the Property will be removed from all Items in the Container.
Parameters
true
if the operation succeeded,
false
if not
Removes an Item specified by
itemId
from the underlying
container and from the ordering.
Parameters
listener
listener to be removed
Removes a Item set change listener from the object.
Parameters
listener
Listener to be removed
Removes a previously registered Property set change listener.