AUI Framework  develop
Cross-platform base for C++ UI apps
Loading...
Searching...
No Matches
AListModel< StoredType > Class Template Reference

Member Function Documentation

> All members, including inherited

◆ at() [1/2]

template<typename StoredType>
StoredType & AListModel< StoredType >::at ( size_t index)
inline

Fetches element by index.

Sneaky exceptions
AException thrown if out of bounds.
Performance note
if guaranteed index is not out of bounds, use the operator[] function instead.
Data model note
A mutable reference returned by this method. If you want to change data, you should report changes by invalidate function.

◆ at() [2/2]

template<typename StoredType>
const StoredType & AListModel< StoredType >::at ( size_t index) const
inline

Fetches element by index.

Sneaky exceptions
AException thrown if out of bounds.
Performance note
if guaranteed index is not out of bounds, use the operator[] function instead.

◆ fromVector() [1/2]

template<typename StoredType>
template<typename V = StoredType>
static _< AListModel< StoredType > > AListModel< StoredType >::fromVector ( AVector< V > t)
inlinestatic

Create AListModel from initializer list. Applicable for initializing AListModel<AString> from const char* initializer list.

Template Parameters
Vtype that converts to T
Returns
a new AListModel

◆ fromVector() [2/2]

template<typename StoredType>
template<typename V>
static _< AListModel< StoredType > > AListModel< StoredType >::fromVector ( std::vector< V > t)
inlinestatic

Create AListModel from initializer list. Applicable for initializing AListModel<AString> from const char* initializer list.

Template Parameters
Vtype that converts to T
Returns
a new AListModel

◆ listItemAt()

template<typename StoredType>
StoredType AListModel< StoredType >::listItemAt ( const AListModelIndex & index)
inlineoverridevirtual

◆ listSize()

template<typename StoredType>
size_t AListModel< StoredType >::listSize ( )
inlineoverridevirtual

◆ make()

template<typename StoredType>
template<typename V = StoredType>
static _< AListModel< StoredType > > AListModel< StoredType >::make ( const std::initializer_list< V > & t)
inlinestatic

Create AListModel from initializer list. Applicable for initializing AListModel<AString> from const char* initializer list.

Template Parameters
Vtype that converts to T
Returns
a new AListModel
Examples
examples/7guis/flight_booker/src/main.cpp.

◆ operator[]()

template<typename StoredType>
const StoredType & AListModel< StoredType >::operator[] ( size_t index) const
inline

Fetches element by index.

Sneaky assertions
index points to the existing element.

◆ removeAt()

template<typename StoredType>
void AListModel< StoredType >::removeAt ( size_t index)
inlinenoexcept

Removes element at the specified index.

Sneaky assertions
index points to the existing element.
Parameters
indexindex of the element.

◆ removeItem()

template<typename StoredType>
void AListModel< StoredType >::removeItem ( const AListModelIndex & item)
inlineoverridevirtual

◆ removeItems()

template<typename StoredType>
void AListModel< StoredType >::removeItems ( const AListModelRange< StoredType > & items)
inlineoverridevirtual

◆ setItem()

template<typename StoredType>
void AListModel< StoredType >::setItem ( const AListModelIndex & item,
const StoredType & value )
inlineoverridevirtual