|
ACF $AcfVersion:0$
|
Representation of fulcrums in multi-dimesional regular grid. More...
#include <TFulcrumGrid.h>
Public Types | |
| enum | ChangeFlags { CF_SORT_LAYERS = 0x8352707 } |
| Data model change notification flags. More... | |
| typedef Fulcrums::ElementType | FulcrumType |
| typedef Fulcrums::IndexType | FulcrumIndex |
| typedef Fulcrums::SizesType | FulcrumSizes |
| typedef Position | PositionType |
Public Types inherited from istd::IChangeable | |
| enum | ChangeFlags { CF_ACF_INTERNAL = 0 , CF_ALL_DATA , CF_ANY , CF_DESTROYING , CF_DELEGATED , CF_NO_UNDO } |
| Data model change notification flags. More... | |
| enum | SupportedOperations { SO_NONE = 0 , SO_OBSERVE = 1 << 0 , SO_COPY = 1 << 1 , SO_CLONE = 1 << 2 , SO_COMPARE = 1 << 3 , SO_RESET = 1 << 4 } |
| Flags for supported operations. More... | |
| enum | CompatibilityMode { CM_STRICT , CM_WITHOUT_REFS , CM_WITH_REFS , CM_CONVERT } |
| Control how relationship betweeen objects are interpreted. More... | |
| typedef QMultiMap< QByteArray, QVariant > | ChangeInfoMap |
Public Member Functions | |
| TFulcrumGrid () | |
| void | Reset () |
| Removes all fulcrum points. | |
| FulcrumSizes | GetGridSize () const |
| Return complete grid size. | |
| int | GetDimensionsCount () const |
| Get number of dimensions. | |
| virtual bool | SetDimensionsCount (int count) |
| Set number of dimensions. | |
| int | GetLayersCount (int dimension) const |
| Get number of fulcrum points used in this function. | |
| virtual void | SetLayersCount (int dimension, int count) |
| Set number of fulcrum layers at specified dimension. | |
| double | GetLayerPosition (int dimension, int layerIndex) const |
| Get position of specified layer of fulcrums. | |
| virtual void | SetLayerPosition (int dimension, int layerIndex, double position) |
| Set position of specified layer of fulcrums. | |
| void | GetFulcrumPosition (const FulcrumIndex &index, PositionType &result) const |
| Get position of node at specified grid index. | |
| const FulcrumType & | GetFulcrumAtIndex (const FulcrumIndex &index) const |
| Get value at specified index. | |
| virtual void | SetFulcrumAtIndex (const FulcrumIndex &index, const FulcrumType &value) |
| Set single fulcrum point. | |
| int | InsertLayer (int dimension, double position) |
| Inserts single fulcrum layer. | |
| virtual void | RemoveLayer (int dimension, int layerIndex) |
| Remove fulcrums at spacified layer. | |
| virtual bool | Serialize (iser::IArchive &archive) override |
| Load or store state of this object as a archive stream. | |
| bool | operator== (const TFulcrumGrid< Position, Fulcrums > &value) const |
| bool | operator!= (const TFulcrumGrid< Position, Fulcrums > &value) const |
Public Member Functions inherited from iser::ISerializable | |
| virtual quint32 | GetMinimalVersion (int versionId) const |
| Get minimal needed version to correct storing of this data. | |
Public Member Functions inherited from istd::IChangeable | |
| virtual int | GetSupportedOperations () const |
| Get set of flags for supported operations. | |
| virtual bool | CopyFrom (const IChangeable &object, CompatibilityMode mode=CM_WITHOUT_REFS) |
| Copy this object from another one. | |
| virtual bool | IsEqual (const IChangeable &object) const |
| Compare this object with another object. | |
| virtual istd::TUniqueInterfacePtr< istd::IChangeable > | CloneMe (CompatibilityMode mode=CM_WITHOUT_REFS) const |
| Make a copy of this object. | |
| virtual bool | ResetData (CompatibilityMode mode=CM_WITHOUT_REFS) |
| Reset data to its default state. | |
| virtual void | BeginChanges (const ChangeSet &changeSet) |
| Starts the change transaction. | |
| virtual void | EndChanges (const ChangeSet &changeSet) |
| Ends the change transaction. | |
| virtual void | BeginChangeGroup (const ChangeSet &changeSet) |
| Starts group of changes. | |
| virtual void | EndChangeGroup (const ChangeSet &changeSet) |
| Ends group of changes. | |
Public Member Functions inherited from istd::IPolymorphic | |
| virtual | ~IPolymorphic () |
Protected Member Functions | |
| virtual void | SortFulcrums () |
| Sort fulcrums in this collection. | |
| int | FindLayerIndex (int dimension, double value) const |
| Find layer index of specified value for specified dimension. | |
| Fulcrums::IndexType | FindIndices (const PositionType &argument) const |
| Find indices of cuboid containing specified argument value. | |
Protected Member Functions inherited from istd::IChangeable | |
| virtual void | OnBeginChanges () |
| Callback function for begin change event. | |
| virtual void | OnEndChanges (const ChangeSet &changeSet) |
| Callback function for end change event. | |
Static Protected Attributes | |
| static const ChangeSet | s_fulcrumPositionChange |
Additional Inherited Members | |
Static Public Member Functions inherited from istd::IChangeable | |
| static const ChangeSet & | GetNoChanges () |
| Get empty set of changes. | |
| static const ChangeSet & | GetAnyChange () |
| Get anonymous change set. | |
| static const ChangeSet & | GetAllChanges () |
| Get anonymous change set. | |
| static const ChangeSet & | GetDelegatedChanges () |
| Get delegated change set. | |
Representation of fulcrums in multi-dimesional regular grid.
This grid may be imagined as set of parallel layers for each dimension. Number of this layers and their position can be individually controlled. Plese note, that method SetDimensionsCount must be called manually to initialize number of input dimensions also for fixed-size arguments.
| Position | type of fulcrum position. |
| Result | function result type. |
| Fulcrums | array type used to stored fulcrums. It muss define following public typedefs
|
Definition at line 33 of file TFulcrumGrid.h.
| typedef Fulcrums::IndexType imath::TFulcrumGrid< Position, Fulcrums >::FulcrumIndex |
Definition at line 37 of file TFulcrumGrid.h.
| typedef Fulcrums::SizesType imath::TFulcrumGrid< Position, Fulcrums >::FulcrumSizes |
Definition at line 38 of file TFulcrumGrid.h.
| typedef Fulcrums::ElementType imath::TFulcrumGrid< Position, Fulcrums >::FulcrumType |
Definition at line 36 of file TFulcrumGrid.h.
| typedef Position imath::TFulcrumGrid< Position, Fulcrums >::PositionType |
Definition at line 39 of file TFulcrumGrid.h.
| enum imath::TFulcrumGrid::ChangeFlags |
Data model change notification flags.
| Enumerator | |
|---|---|
| CF_SORT_LAYERS | |
Definition at line 44 of file TFulcrumGrid.h.
| imath::TFulcrumGrid< Position, Fulcrums >::TFulcrumGrid | ( | ) |
Definition at line 207 of file TFulcrumGrid.h.
|
protected |
Find indices of cuboid containing specified argument value.
Definition at line 539 of file TFulcrumGrid.h.
|
protected |
Find layer index of specified value for specified dimension.
| dimension | specifies dimension should be used. |
| value | argument value. |
Definition at line 512 of file TFulcrumGrid.h.
|
inline |
Get number of dimensions.
Definition at line 173 of file TFulcrumGrid.h.
| const TFulcrumGrid< Position, Fulcrums >::FulcrumType & imath::TFulcrumGrid< Position, Fulcrums >::GetFulcrumAtIndex | ( | const FulcrumIndex & | index | ) | const |
Get value at specified index.
Definition at line 289 of file TFulcrumGrid.h.
| void imath::TFulcrumGrid< Position, Fulcrums >::GetFulcrumPosition | ( | const FulcrumIndex & | index, |
| PositionType & | result | ||
| ) | const |
Get position of node at specified grid index.
Definition at line 269 of file TFulcrumGrid.h.
|
inline |
Return complete grid size.
Definition at line 166 of file TFulcrumGrid.h.
|
inline |
Get position of specified layer of fulcrums.
Definition at line 190 of file TFulcrumGrid.h.
|
inline |
Get number of fulcrum points used in this function.
Definition at line 180 of file TFulcrumGrid.h.
| int imath::TFulcrumGrid< Position, Fulcrums >::InsertLayer | ( | int | dimension, |
| double | position | ||
| ) |
Inserts single fulcrum layer.
Definition at line 305 of file TFulcrumGrid.h.
References I_BIG_EPSILON, and I_EPSILON.
| bool imath::TFulcrumGrid< Position, Fulcrums >::operator!= | ( | const TFulcrumGrid< Position, Fulcrums > & | value | ) | const |
Definition at line 492 of file TFulcrumGrid.h.
| bool imath::TFulcrumGrid< Position, Fulcrums >::operator== | ( | const TFulcrumGrid< Position, Fulcrums > & | value | ) | const |
Definition at line 485 of file TFulcrumGrid.h.
|
virtual |
Remove fulcrums at spacified layer.
Definition at line 376 of file TFulcrumGrid.h.
| void imath::TFulcrumGrid< Position, Fulcrums >::Reset | ( | ) |
Removes all fulcrum points.
Definition at line 214 of file TFulcrumGrid.h.
|
overridevirtual |
Load or store state of this object as a archive stream.
Type of operation is depending on archive type.
Implements iser::ISerializable.
Definition at line 407 of file TFulcrumGrid.h.
References iser::IArchive::BeginMultiTag(), iser::IArchive::BeginTag(), iser::IArchive::EndTag(), iser::IArchive::IsStoring(), NULL, iser::IArchive::Process(), iser::CArchiveTag::TT_GROUP, iser::CArchiveTag::TT_LEAF, and iser::CArchiveTag::TT_MULTIPLE.
|
virtual |
Set number of dimensions.
Please note, that depending on used array type for grid representation not all values must be supported.
Definition at line 227 of file TFulcrumGrid.h.
|
virtual |
Set single fulcrum point.
Definition at line 296 of file TFulcrumGrid.h.
|
virtual |
Set position of specified layer of fulcrums.
Please note, that layer are sorted by its position during update. If you want to block update mechanism, use istd::TUpdateNotifier.
Definition at line 251 of file TFulcrumGrid.h.
|
virtual |
Set number of fulcrum layers at specified dimension.
Please note, that this fulcrum velues will be not valid after this operation.
Definition at line 240 of file TFulcrumGrid.h.
|
protectedvirtual |
Sort fulcrums in this collection.
Definition at line 501 of file TFulcrumGrid.h.
|
staticprotected |
Definition at line 149 of file TFulcrumGrid.h.