hestia_earth.calculation.utils.EngineList

class hestia_earth.calculation.utils.EngineList(iterable=(), /)[source]

Bases: list

EngineList class. This class also extends lists in order to covert them easily to EngineDict, that is the data structure used for the Engine representation.

Methods

append

Append object to the end of the list.

clear

Remove all items from list.

copy

Return a shallow copy of the list.

count

Return number of occurrences of value.

extend

Extend list by appending elements from the iterable.

index

Return first index of value.

insert

Insert object before index.

pop

Remove and return item at index (default last).

remove

Remove first occurrence of value.

reverse

Reverse IN PLACE.

sort

Stable sort IN PLACE.

to_edict

Method to generate an EngineDict from an EngineList.

__add__(value, /)

Return self+value.

__mul__(value, /)

Return self*value.

append(object, /)

Append object to the end of the list.

clear()

Remove all items from list.

copy()

Return a shallow copy of the list.

count(value, /)

Return number of occurrences of value.

extend(iterable, /)

Extend list by appending elements from the iterable.

index(value, start=0, stop=9223372036854775807, /)

Return first index of value.

Raises ValueError if the value is not present.

insert(index, object, /)

Insert object before index.

pop(index=-1, /)

Remove and return item at index (default last).

Raises IndexError if list is empty or index is out of range.

remove(value, /)

Remove first occurrence of value.

Raises ValueError if the value is not present.

reverse()

Reverse IN PLACE.

sort(*, key=None, reverse=False)

Stable sort IN PLACE.

to_edict()[source]

Method to generate an EngineDict from an EngineList. :param None:

Returns EngineDict.