GeListHead Class Reference

#include <c4d_baselist.h>

Inheritance diagram for GeListHead:

Detailed Description

Stores a list of GeListNode objects.

Note
Has to be created with Alloc() and destroyed with Free(). Use AutoAlloc to automate the allocation and destruction based on scope.

Private Member Functions

 GeListHead ()
 
 ~GeListHead ()
 

Navigation

void InsertBefore (GeListNode *bl)
 
void InsertAfter (GeListNode *bl)
 
void InsertUnder (GeListNode *bl)
 
void InsertUnderLast (GeListNode *bl)
 
void Remove ()
 

Alloc/Free

static GeListHeadAlloc ()
 
static void Free (GeListHead *&v)
 

Miscellaneous

void SetParent (GeListNode *parent)
 
GeListNodeGetParent ()
 
const GeListNodeGetParent () const
 
GeListNodeGetFirst ()
 
const GeListNodeGetFirst () const
 
GeListNodeGetLast ()
 
const GeListNodeGetLast () const
 
void FlushAll ()
 

Insertion

void InsertFirst (GeListNode *bn)
 
void InsertLast (GeListNode *bn)
 
void Insert (GeListNode *bn, GeListNode *parent, GeListNode *prev)
 

Additional Inherited Members

- Public Member Functions inherited from GeListNode
GeListNodeGetNext ()
 
const GeListNodeGetNext () const
 
GeListNodeGetPred ()
 
const GeListNodeGetPred () const
 
GeListNodeGetDown ()
 
const GeListNodeGetDown () const
 
GeListNodeGetUp ()
 
const GeListNodeGetUp () const
 
GeListNodeGetDownLast ()
 
const GeListNodeGetDownLast () const
 
void InsertBefore (GeListNode *bl)
 
void InsertAfter (GeListNode *bl)
 
void InsertUnder (GeListNode *bl)
 
void InsertUnderLast (GeListNode *bl)
 
void Remove ()
 
void FlushChilds ()
 
void MoveChildrenTo (GeListNode *dest)
 
GeListHeadGetListHead ()
 
const GeListHeadGetListHead () const
 
Int32 GetNodeID (Int32 index=0) const
 
template<typename CAST >
const CAST * GetNodeData (Int32 index=0) const
 
template<typename CAST >
CAST * GetNodeData (Int32 index=0)
 
void SetCustomData (GeListNode *node)
 
GeListNodeGetCustomData ()
 
const GeListNodeGetCustomData () const
 
const BaseDocumentGetDocument () const
 
BaseDocumentGetDocument ()
 
maxon::Result< BoolGetBranchInfo (const maxon::ValueReceiver< const BranchInfo & > &info, GETBRANCHINFO flags) const
 
Bool IsDocumentRelated () const
 
Int32 GetInfo () const
 
Bool GetNBit (NBIT bit) const
 
UInt32 GetNBitMask (Int32 index) const
 
Bool ChangeNBit (NBIT bit, NBITCONTROL bitmode)
 
- Public Member Functions inherited from C4DAtom
Int32 GetType () const
 
Int32 GetRealType () const
 
Int32 GetDiskType () const
 
Bool IsInstanceOf (Int32 id) const
 
Int32 GetClassification () const
 
Bool Message (Int32 type, void *data=nullptr)
 
Bool MultiMessage (MULTIMSG_ROUTE flags, Int32 type, void *data)
 
C4DAtomGetClone (COPYFLAGS flags, AliasTrans *trn) const
 
Bool CopyTo (C4DAtom *dst, COPYFLAGS flags, AliasTrans *trn) const
 
Bool Read (HyperFile *hf, Int32 id, Int32 level)
 
Bool Write (HyperFile *hf) const
 
Bool ReadObject (HyperFile *hf, Bool readheader)
 
Bool WriteObject (HyperFile *hf) const
 
Bool GetDescription (Description *description, DESCFLAGS_DESC flags) const
 
Bool GetParameter (const DescID &id, GeData &t_data, DESCFLAGS_GET flags) const
 
Bool SetParameter (const DescID &id, const GeData &t_data, DESCFLAGS_SET flags)
 
DynamicDescriptionGetDynamicDescriptionWritable ()
 
const DynamicDescriptionGetDynamicDescription () const
 
Bool CopyDynamicDescriptionFrom (const BaseList2D *src)
 
Bool GetEnabling (const DescID &id, const GeData &t_data, DESCFLAGS_ENABLE flags, const BaseContainer *itemdesc) const
 
Bool TranslateDescID (const DescID &id, DescID &res_id, C4DAtom *&res_at)
 
UInt32 GetDirty (DIRTYFLAGS flags) const
 
void SetDirty (DIRTYFLAGS flags)
 
UInt32 GetHDirty (HDIRTYFLAGS mask) const
 
void SetHDirty (HDIRTYFLAGS mask)
 

Constructor & Destructor Documentation

◆ GeListHead()

GeListHead ( )
private

◆ ~GeListHead()

~GeListHead ( )
private

Member Function Documentation

◆ InsertBefore()

void InsertBefore ( GeListNode bl)
private

◆ InsertAfter()

void InsertAfter ( GeListNode bl)
private

◆ InsertUnder()

void InsertUnder ( GeListNode bl)
private

◆ InsertUnderLast()

void InsertUnderLast ( GeListNode bl)
private

◆ Remove()

void Remove ( )
private

◆ Alloc()

static GeListHead* Alloc ( )
static

Allocates a list head. Destroy the allocated list head with Free(). Use AutoAlloc to automate the allocation and destruction based on scope.

Returns
The allocated list head, or nullptr if the allocation failed.

◆ Free()

static void Free ( GeListHead *&  v)
static

Destructs list heads allocated with Alloc(). Use AutoAlloc to automate the allocation and destruction based on scope.

Parameters
[in,out]vThe list head to destruct. If the pointer is nullptr nothing happens. The pointer is assigned nullptr afterwards.

◆ SetParent()

void SetParent ( GeListNode parent)

Sets the parent of the list head.
Usually called directly after the list head is allocated.

Parameters
[in]parentThe new parent. The caller owns the pointed parent.

◆ GetParent() [1/2]

GeListNode* GetParent ( )

Gets the parent of the list head.
For the tag list head this would be the object, for the object list head this would be the document etc.

Returns
The parent. Cinema 4D owns the pointed parent.

◆ GetParent() [2/2]

const GeListNode* GetParent ( ) const

◆ GetFirst() [1/2]

GeListNode* GetFirst ( )

Gets the first node in the list.

Returns
The first node in the list. The list owns the pointed node.

◆ GetFirst() [2/2]

const GeListNode* GetFirst ( ) const

◆ GetLast() [1/2]

GeListNode* GetLast ( )

Gets the last node in the list.

Returns
The last node in the list. The list owns the pointed node.

◆ GetLast() [2/2]

const GeListNode* GetLast ( ) const

◆ FlushAll()

void FlushAll ( )

Clears the list, removing all nodes.

◆ InsertFirst()

void InsertFirst ( GeListNode bn)

Inserts bn as the first element in the list.

Parameters
[in]bnThe node to insert first. The caller owns the pointed node.

◆ InsertLast()

void InsertLast ( GeListNode bn)

Inserts bn as the last element in the list.

Parameters
[in]bnThe node to insert last. The caller owns the pointed node.

◆ Insert()

void Insert ( GeListNode bn,
GeListNode parent,
GeListNode prev 
)

Inserts bn as a child of parent or after prev.

Parameters
[in]bnThe node to insert. The caller owns the pointed node.
[in]parentThe node to insert bn as child. The caller owns the pointed node.
[in]prevThe node to insert bn after. The caller owns the pointed node.