C3D Toolkit  Kernel - 110050, Vision - 2.5.0.18

Set of object properties. More...

#include <mb_property.h>

+ Inheritance diagram for MbProperties:
+ Collaboration diagram for MbProperties:

Public Member Functions

 MbProperties ()
 Constructor.
 
MbePromptSetName ()
 Get name of object.
 
size_t GetName () const
 Get name of object.
 
MbePrompt Name () const
 Get name of object.
 
void SetName (MbePrompt s)
 Set name of the object.
 
void SetName (size_t s)
 Set name of the object.
 
MbPropertyFindByPrompt (MbePrompt, uint type) const
 Find property by name and type.
 
size_t FindByPrompt (uint type, MbePrompt) const
 Find index of property in array by name and type.
 
- Public Member Functions inherited from PArray< MbProperty >
 PArray ()
 Constructor.
 
 PArray (size_t i_upper, uint16 i_delta=1, bool shouldDelete=true)
 Constructor.
 
virtual ~PArray ()
 Destructor.
 
bool OwnsElem () const
 Are the elements owned?
 
void OwnsElem (bool ownsEl)
 Set the flag of elements ownership.
 
bool SetSize (size_t newSize, bool clear)
 Functions that allocate potentially large memory, return an operation result (success/error). More...
 
void Flush (DelType=defDelete)
 Delete all elements.
 
void HardFlush (DelType shdl=defDelete)
 Free the whole memory.
 
void RemoveAll (DelType shdl=defDelete)
 Delete all elements and set the number of elements to null.
 
MbPropertyRemoveObj (MbProperty *delObject, DelType=defDelete)
 Delete an element from array.
 
virtual MbPropertyRemoveInd (size_t delIndex, DelType del=defDelete)
 Delete an element from array.
 
virtual void clear ()
 Set the number of elements to null.
 
- Public Member Functions inherited from RPArray< MbProperty >
 RPArray ()
 Constructor.
 
 RPArray (size_t i_upper, uint16 i_delta=1)
 Constructor.
 
virtual ~RPArray ()
 Destructor.
 
uint16 Delta () const
 Get the increment by the number of elements while the allocation of additional memory.
 
void Delta (uint16 newDelta)
 Set the increment by the number of elements while the allocation of additional memory (1 - autoincrement).
 
size_t Upper () const
 The number of elements the memory is allocated for.
 
void SetMaxDelta (uint16 newDelta)
 Set the maximum increment.
 
bool SetSize (size_t newSize)
 Functions that allocate potentially large memory, return an operation result (success/error). More...
 
bool Reserve (size_t n, bool addAdditionalSpace=true)
 Reserve space for a given number of elements.
 
bool Add (MbProperty *)
 Add an element to the end of the array.
 
bool AddAt (MbProperty *e, size_t index)
 Insert an element to the given position.
 
bool AddAfter (MbProperty *e, size_t index)
 Add an element after the specified one.
 
bool Insert (size_t index, MbProperty *)
 Insert an element before the specified one.
 
bool AddArray (const RPArray< MbProperty > &)
 Add array.
 
bool AddCArray (const MbProperty **, size_t count)
 Add C-array.
 
bool InsertArray (const RPArray< MbProperty > &, size_t index)
 Add an array to the position.
 
void DetachAll ()
 Delete all elements and set the number of elements to null.
 
void Adjust ()
 Free the unnecessary memory.
 
MbPropertyDetachInd (size_t delIndex)
 Detach an element from the array.
 
bool DetachObj (const MbProperty *delObject)
 Detach an element from the array.
 
void Swap (RPArray &arr)
 Swap data of arrays.
 
size_t FindIt (const MbProperty *) const
 Find an element by a pointer.
 
bool IsExist (const MbProperty *) const
 Whether an element belongs the array.
 
size_t Count () const
 Get the number of array elements.
 
ptrdiff_t MaxIndex () const
 Get the index of the last element in the array.
 
void Sort (CompFunc comp)
 Sort the array.
 
MbProperty *& operator[] (size_t loc) const
 Access by index operator.
 
MbPropertyGetLast () const
 Get the address of the last element in the array.
 
size_t size () const
 Get the number of elements in array.
 
bool reserve (size_t n)
 Reserve space for a given number of elements.
 
size_t capacity () const
 What is the number of elements the memory is allocated for?
 
void push_back (const MbProperty *e)
 Add an element to the end of the array.
 
void insert (Iterator pos, const MbProperty *e)
 Insert an element before the specified one.
 
void erase (Iterator pos)
 Delete an element from array by the index.
 
void erase (Iterator first, Iterator last)
 Delete elements from the array from first to last-1 inclusively.
 
void shrink_to_fit ()
 Free the unnecessary memory (Reduce capacity).
 
const TPtrbegin () const
 Get the pointer to the first array element.
 
TPtrbegin ()
 Get the pointer to the first array element.
 
const TPtrend () const
 Get the pointer to the piece of memory after the array.
 
TPtrend ()
 Get the pointer to the piece of memory after the array.
 
const TPtrcbegin () const
 Get the pointer to the first array element.
 
const TPtrcend () const
 Get the pointer to the piece of memory after the array.
 

Additional Inherited Members

- Public Types inherited from RPArray< MbProperty >
typedef MbPropertyTPtr
 A name of the pointer to the object.
 
typedef int(* CompFunc) (const MbProperty **, const MbProperty **)
 A template of sorting function.
 
- Protected Member Functions inherited from RPArray< MbProperty >
const MbProperty ** GetAddr () const
 Get the pointer to the first array element.
 
const TPtr_Begin () const
 Get the pointer to the first array element.
 
TPtr_Begin ()
 Get the pointer to the first array element.
 
const TPtr_End () const
 Get the pointer to the piece of memory after the array.
 
bool CatchMemory ()
 Catch memory.
 
bool AddMemory (size_t n)
 Provide memory for n elements, independently from AutoDelta.
 
size_t AutoDelta () const
 Calculate autoincrement.
 
- Protected Attributes inherited from PArray< MbProperty >
bool owns
 A flag of ownership of elements of an array (elements can be deleted)
 
MbPropertynowDeletedElem
 Deleted element.
 
- Protected Attributes inherited from RPArray< MbProperty >
size_t count
 The number of elements in array.
 
size_t upper
 The number of elements the memory is allocated for.
 
uint16 delta
 Increment by the number of elements while the allocation of additional memory.
 

Detailed Description

Set of object properties.

Set of object properties is container that calls destructor of its elements.


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