public static class UtlPlist.Element<T> extends UtlListElement implements UtlPool.Item<UtlPlist.Element<T>>
The plist maintains an internal list into which it links element objects that indirect to user objects. This class is the default element object used by the plist. The user can extend this class to add its own meta fields or specify that this class be used as is as the list element.
count, head, next, prev
Modifier and Type | Method and Description |
---|---|
T |
getObject()
Get the user object
|
UtlPool<UtlPlist.Element<T>> |
getPool()
Get a pool item's pool.
|
UtlPlist.Element<T> |
init()
Initialize an item.
|
UtlPlist.Element<T> |
setObject(T object) |
UtlPlist.Element<T> |
setPool(UtlPool<UtlPlist.Element<T>> pool)
Set a pool item's pool.
|
count, insertAfter, insertBefore, isLinked, next, previous, unlink, wipe
public final UtlPlist.Element<T> setObject(T object)
public final T getObject()
public final UtlPlist.Element<T> setPool(UtlPool<UtlPlist.Element<T>> pool)
UtlPool.Item
This method is invoked by an item pool at the time an item is added to the pool. The intent is to record the item's source pool in the item so it can be disposed back into the pool when the user is done working with it.
setPool
in interface UtlPool.Item<UtlPlist.Element<T>>
public final UtlPool<UtlPlist.Element<T>> getPool()
UtlPool.Item
This method should return the pool set using UtlPool.Item.setPool(com.neeve.util.UtlPool<T>)
getPool
in interface UtlPool.Item<UtlPlist.Element<T>>
UtlPool.Item.setPool(com.neeve.util.UtlPool<T>)
public final UtlPlist.Element<T> init()
UtlPool.Item
This method is invoked by an item pool very time an item is put into the pool. The method should wipe the contents of the item so as to present a fresh instance of the item to the caller when retrieved from the pool.
init
in interface UtlPool.Item<UtlPlist.Element<T>>
Copyright © 2019 Neeve Research, LLC. All Rights Reserved.