KEYTYPE - The key type.DATATYPE - The value type to be contained in tree items.ITEMTYPE - tree item typepublic interface ITreeItemWithIDFactory<KEYTYPE,DATATYPE,ITEMTYPE extends ITreeItemWithID<KEYTYPE,DATATYPE,ITEMTYPE>> extends IHierarchicalFactoryWithParameter<ITEMTYPE,KEYTYPE>, IHierarchicalRootFactory<ITEMTYPE>
| Modifier and Type | Method and Description |
|---|---|
ITEMTYPE |
create(ITEMTYPE aParent,
KEYTYPE aDataID)
Create an object of the desired type.
|
ITEMTYPE |
createRoot()
Create the root object.
|
void |
onAddItem(ITEMTYPE aItem)
To be called once a tree item is added to the owning tree.
|
void |
onRemoveItem(ITEMTYPE aItem)
To be called once a tree item is removed from the owning tree.
|
@Nonnull ITEMTYPE createRoot()
createRoot in interface IHierarchicalRootFactory<ITEMTYPE extends ITreeItemWithID<KEYTYPE,DATATYPE,ITEMTYPE>>null depending on the
implementation.ITEMTYPE create(@Nonnull ITEMTYPE aParent, @Nonnull KEYTYPE aDataID)
create in interface IHierarchicalFactoryWithParameter<ITEMTYPE extends ITreeItemWithID<KEYTYPE,DATATYPE,ITEMTYPE>,KEYTYPE>aParent - The parent item to use. May be null depending on the
implementation.aDataID - The parameter to be passed. May be null depending on
the implementation.null depending on the
implementation.void onRemoveItem(@Nonnull ITEMTYPE aItem)
aItem - The item that was removed.Copyright © 2014–2016 Philip Helger. All rights reserved.