kanzi::DefaultListBoxItemGenerator< TBaseItemGenerator > Class Template Reference

#include <kanzi/ui/node/concept/list_box/default_list_box_item_generator.hpp>

Inheritance diagram for kanzi::DefaultListBoxItemGenerator< TBaseItemGenerator >:

Public Types

typedef shared_ptr< DefaultListBoxItemGenerator< TBaseItemGenerator > > DefaultListBoxItemGeneratorSharedPtr
 

Public Member Functions

size_t getListCount ()
 Returns the number of objects controlled by the list interface. More...
 
TBaseItemGenerator::ItemSharedPtr getListObject (size_t index)
 Gets the object at the given index of the list. More...
 
optional< size_t > findListIndex (typename TBaseItemGenerator::ItemSharedPtr const &object)
 Finds index of the given object in the list. More...
 
void insertListObject (size_t index, typename TBaseItemGenerator::ItemSharedPtr object)
 Inserts an object at the given index. More...
 
void removeListObject (size_t index)
 Removes an object at the given index from the object generator's list. More...
 
void replaceListObject (size_t index, typename TBaseItemGenerator::ItemSharedPtr object)
 Replaces the object at the given index in the object generator's list. More...
 
virtual void attach (typename TBaseItemGenerator::ListBoxType &) KZ_OVERRIDE
 Attaches the Object Generator. More...
 
virtual void detach (typename TBaseItemGenerator::ListBoxType &) KZ_OVERRIDE
 Detaches the Object Generator. More...
 
virtual TBaseItemGenerator::ItemSharedPtr acquireItem (size_t index) KZ_OVERRIDE
 Gets an object that should be displayed at the given index. More...
 
virtual void releaseItem (typename TBaseItemGenerator::ItemSharedPtr) KZ_OVERRIDE
 Frees an object that has been returned from getObject. More...
 
virtual optional< size_t > getItemIndex (typename TBaseItemGenerator::ItemSharedPtr object) KZ_OVERRIDE
 Gets index of an object that has been returned from getObject, or KZU_UI_LIST_BOX_NO_ITEM if the object does not exist. More...
 
virtual TBaseItemGenerator::VectorType getItemSize (size_t index) KZ_OVERRIDE
 Gets exact size of the object that should be displayed at the given index. More...
 
virtual size_t getCount () KZ_OVERRIDE
 Gets the number of objects known by the object generator. More...
 

Static Public Member Functions

static PropertyTypeEditorInfoSharedPtr makeEditorInfo ()
 
static DefaultListBoxItemGeneratorSharedPtr create (Domain *domain, string_view)
 
static void doRemeasure (Node3D &node)
 
static void doRemeasure (Node2D &node)
 
static void doArrange (Node3D &node)
 
static void doArrange (Node2D &node)
 

Protected Member Functions

 DefaultListBoxItemGenerator (Domain *domain)
 

Member Typedef Documentation

template<typename TBaseItemGenerator >
typedef shared_ptr<DefaultListBoxItemGenerator<TBaseItemGenerator> > kanzi::DefaultListBoxItemGenerator< TBaseItemGenerator >::DefaultListBoxItemGeneratorSharedPtr

Constructor & Destructor Documentation

template<typename TBaseItemGenerator >
kanzi::DefaultListBoxItemGenerator< TBaseItemGenerator >::DefaultListBoxItemGenerator ( Domain domain)
inlineexplicitprotected

Member Function Documentation

template<typename TBaseItemGenerator >
static PropertyTypeEditorInfoSharedPtr kanzi::DefaultListBoxItemGenerator< TBaseItemGenerator >::makeEditorInfo ( )
inlinestatic
template<typename TBaseItemGenerator >
static DefaultListBoxItemGeneratorSharedPtr kanzi::DefaultListBoxItemGenerator< TBaseItemGenerator >::create ( Domain domain,
string_view   
)
inlinestatic
template<typename TBaseItemGenerator >
size_t kanzi::DefaultListBoxItemGenerator< TBaseItemGenerator >::getListCount ( )
inline

Returns the number of objects controlled by the list interface.

template<typename TBaseItemGenerator >
TBaseItemGenerator::ItemSharedPtr kanzi::DefaultListBoxItemGenerator< TBaseItemGenerator >::getListObject ( size_t  index)
inline

Gets the object at the given index of the list.

template<typename TBaseItemGenerator >
optional<size_t> kanzi::DefaultListBoxItemGenerator< TBaseItemGenerator >::findListIndex ( typename TBaseItemGenerator::ItemSharedPtr const &  object)
inline

Finds index of the given object in the list.

template<typename TBaseItemGenerator >
void kanzi::DefaultListBoxItemGenerator< TBaseItemGenerator >::insertListObject ( size_t  index,
typename TBaseItemGenerator::ItemSharedPtr  object 
)
inline

Inserts an object at the given index.

template<typename TBaseItemGenerator >
void kanzi::DefaultListBoxItemGenerator< TBaseItemGenerator >::removeListObject ( size_t  index)
inline

Removes an object at the given index from the object generator's list.

template<typename TBaseItemGenerator >
void kanzi::DefaultListBoxItemGenerator< TBaseItemGenerator >::replaceListObject ( size_t  index,
typename TBaseItemGenerator::ItemSharedPtr  object 
)
inline

Replaces the object at the given index in the object generator's list.

template<typename TBaseItemGenerator >
virtual void kanzi::DefaultListBoxItemGenerator< TBaseItemGenerator >::attach ( typename TBaseItemGenerator::ListBoxType &  )
inlinevirtual

Attaches the Object Generator.

template<typename TBaseItemGenerator >
virtual void kanzi::DefaultListBoxItemGenerator< TBaseItemGenerator >::detach ( typename TBaseItemGenerator::ListBoxType &  )
inlinevirtual

Detaches the Object Generator.

template<typename TBaseItemGenerator >
virtual TBaseItemGenerator::ItemSharedPtr kanzi::DefaultListBoxItemGenerator< TBaseItemGenerator >::acquireItem ( size_t  index)
inlinevirtual

Gets an object that should be displayed at the given index.

If the object has already been created and not freed afterwards, returns the object from cache.

template<typename TBaseItemGenerator >
virtual void kanzi::DefaultListBoxItemGenerator< TBaseItemGenerator >::releaseItem ( typename TBaseItemGenerator::ItemSharedPtr  )
inlinevirtual

Frees an object that has been returned from getObject.

template<typename TBaseItemGenerator >
virtual optional<size_t> kanzi::DefaultListBoxItemGenerator< TBaseItemGenerator >::getItemIndex ( typename TBaseItemGenerator::ItemSharedPtr  object)
inlinevirtual

Gets index of an object that has been returned from getObject, or KZU_UI_LIST_BOX_NO_ITEM if the object does not exist.

template<typename TBaseItemGenerator >
static void kanzi::DefaultListBoxItemGenerator< TBaseItemGenerator >::doRemeasure ( Node3D node)
inlinestatic
template<typename TBaseItemGenerator >
static void kanzi::DefaultListBoxItemGenerator< TBaseItemGenerator >::doRemeasure ( Node2D node)
inlinestatic
template<typename TBaseItemGenerator >
static void kanzi::DefaultListBoxItemGenerator< TBaseItemGenerator >::doArrange ( Node3D node)
inlinestatic
template<typename TBaseItemGenerator >
static void kanzi::DefaultListBoxItemGenerator< TBaseItemGenerator >::doArrange ( Node2D node)
inlinestatic
template<typename TBaseItemGenerator >
virtual TBaseItemGenerator::VectorType kanzi::DefaultListBoxItemGenerator< TBaseItemGenerator >::getItemSize ( size_t  index)
inlinevirtual

Gets exact size of the object that should be displayed at the given index.

This size will be used unless the list box is provided an object prototype. If it is not possible to determine item size, unbounded layout value is returned. Caching the sizes may be a good idea.

template<typename TBaseItemGenerator >
virtual size_t kanzi::DefaultListBoxItemGenerator< TBaseItemGenerator >::getCount ( )
inlinevirtual

Gets the number of objects known by the object generator.

Last index can be calculated as 'count' - 1.


The documentation for this class was generated from the following file: