c4d.GeListHead

class c4d.GeListHead

Stores a list of GeListNode objects.

New in version R19.

Parent Class:

Overview

Insertion Operations

GeListHead.Insert()

Inserts node as a child of parent or after prev.

GeListHead.InsertFirst()

Inserts node as the first element in the list.

GeListHead.InsertLast()

Inserts node as the last element in the list.

Magic Methods

GeListHead.__init__()

Creates a list head.

Structure And Lifecycle

GeListHead.FlushAll()

Clears the list, removing all nodes.

GeListHead.GetFirst()

Returns the first node in the list.

GeListHead.GetLast()

Returns the last node in the list.

GeListHead.GetParent()

Returns the parent of the list head.

GeListHead.SetParent()

Sets the parent of the list head.

Members

Insertion Operations

GeListHead.Insert(self, node, parent, prev)

Inserts node as a child of parent or after prev.

Parameters
GeListHead.InsertFirst(self, node)

Inserts node as the first element in the list.

Parameters

node (c4d.GeListNode) – The node to insert first.

GeListHead.InsertLast(self, node)

Inserts node as the last element in the list.

Parameters

node (c4d.GeListNode) – The node to insert last.

Magic Methods

GeListHead.__init__(self, type)

Creates a list head.

Parameters

type (int) – The id of the object, e.g: (Ocube).

Structure And Lifecycle

GeListHead.FlushAll(self)

Clears the list, removing all nodes.

GeListHead.GetFirst(self)

Returns the first node in the list.

Return type

c4d.GeListNode

Returns

The first child node in the list.

GeListHead.GetLast(self)

Returns the last node in the list.

Return type

c4d.GeListNode

Returns

The last child node in the list.

GeListHead.GetParent(self)
Returns 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.
Return type

Optional[c4d.GeListNode]

Returns

The parent, or None if the list head has no parent.

GeListHead.SetParent(self, parent)
Sets the parent of the list head.
Usually called directly after the list head is created.
Parameters

parent (c4d.GeListNode) – The parent to set.