Geogram
Version 1.9.1-rc
A programming library of geometric algorithms
|
Base class for attributes. They are notified whenever the AttributeStore is modified. More...
#include <geogram/basic/attributes.h>
Public Member Functions | |
AttributeStoreObserver () | |
Creates a new uninitialied AttributeStore. | |
void | notify (Memory::pointer base_addr, index_t size, index_t dim) |
Callback function, called by the AttributeStore whenever it is modified. More... | |
index_t | size () const |
Gets the size. More... | |
index_t | dimension () const |
Gets the dimension. More... | |
index_t | nb_elements () const |
Gets the total number of elements. More... | |
void | register_me (AttributeStore *store) |
Registers this observer to an AttributeStore. More... | |
void | unregister_me (AttributeStore *store) |
Unregisters this observer from an AttributeStore. More... | |
void | disconnect () |
Disconnects this AttributeStoreObserver from its AttributeStore. More... | |
Protected Attributes | |
Memory::pointer | base_addr_ |
index_t | size_ |
index_t | dimension_ |
bool | disconnected_ |
Base class for attributes. They are notified whenever the AttributeStore is modified.
Definition at line 70 of file attributes.h.
|
inline |
Gets the dimension.
Definition at line 108 of file attributes.h.
|
inline |
Disconnects this AttributeStoreObserver from its AttributeStore.
This function is called whenever the AttributesManager is destroyed before the Attributes (can occur when using Lua scripting with Attribute wrapper objects).
Definition at line 141 of file attributes.h.
|
inline |
Gets the total number of elements.
This corresponds to one position past the last valid index.
Definition at line 118 of file attributes.h.
|
inline |
Callback function, called by the AttributeStore whenever it is modified.
[in] | base_addr | new base address of the AttributeStore |
[in] | size | new number of items in the AttributeStore |
[in] | dim | new dimension, i.e. number of elements per item |
Definition at line 88 of file attributes.h.
void GEO::AttributeStoreObserver::register_me | ( | AttributeStore * | store | ) |
Registers this observer to an AttributeStore.
[in] | store | a pointer to the AttributeStore. |
|
inline |
void GEO::AttributeStoreObserver::unregister_me | ( | AttributeStore * | store | ) |
Unregisters this observer from an AttributeStore.
[in] | store | a pointer to the AttributeStore. |