Home

List<H>

List of generics

Operations

New

Default constructor

New()

AddBack

Adds a value to the end

method : public : native : AddBack(value:H) ~ Nil
Parameters
NameTypeDescription
valueHvalue to append

AddFront

Adds a value to the front

method : public : native : AddFront(value:H) ~ Nil
Parameters
NameTypeDescription
valueHvalue to prepend

Apply

Applies the given function to each value in the list

method : public : Apply(f:(H)~H) ~ List<H>
Parameters
NameTypeDescription
f(H)~Hfunction to apply

Return
TypeDescription
List<H>newly calculated list

Back

Returns the last element in the list

method : public : Back() ~ H
Return
TypeDescription
Hlast element in the list, 0.0 if the list is empty

Each

Function called for each element

method : public : Each(f:(H)~Nil) ~ List<H>
Parameters
NameTypeDescription
f(H)~Nilfunction called

Empty

Clears the list

method : public : Empty() ~ Nil

Filter

Uses the given function to filter out values

method : public : Filter(f:(H)~Bool) ~ List<H>
Parameters
NameTypeDescription
f(H)~Boolfunction to use a filter. If the function evaluates to true the value is added to the collection.

Return
TypeDescription
List<H>filtered list

Forward

Moves the pointer to the end of the list

method : public : Forward() ~ Nil

Front

Returns the first element in the list

method : public : Front() ~ H
Return
TypeDescription
Hfirst element in the list, 0.0 if the list is empty

Get

Gets the value that's currently pointed to

method : public : Get() ~ H
Return
TypeDescription
Hvalue value

Insert

Inserts a value into the list based upon the pointer location

method : public : native : Insert(value:H) ~ Bool
Parameters
NameTypeDescription
valueHvalue to insert

IsBack

Checks to see if the pointer is at the end of the list

method : public : IsBack() ~ Bool
Return
TypeDescription
Booltrue if pointer is at the end of the list, false otherwise

IsEmpty

Checks to see if the list is empty

method : public : IsEmpty() ~ Bool
Return
TypeDescription
Booltrue if empty, false otherwise

IsFront

Checks to see if the pointer is at the front of the list

method : public : IsFront() ~ Bool
Return
TypeDescription
Booltrue if pointer is at the front of the list, false otherwise

Limit

Returns a limited list

method : public : Limit(l:Int) ~ List<H>
Parameters
NameTypeDescription
lIntlimit

Return
TypeDescription
List<H>limited list

More

Checks to see the pointer can be advanced

method : public : More() ~ Bool
Return
TypeDescription
Booltrue if pointer can be advanced, false otherwise

Next

Advances the pointer

method : public : Next() ~ Nil

Previous

Retreats the pointer

method : public : Previous() ~ Nil

Remove

Removes the element at the pointer position

method : public : native : Remove() ~ Nil

RemoveBack

Removes the last value from the list

method : public : RemoveBack() ~ Nil

RemoveFront

Removes the first value from the list

method : public : RemoveFront() ~ Nil

Rest

List of all but first element

method : public : Rest() ~ List<H>
Return
TypeDescription
List<H>all but first element

Rewind

Moves the pointer to the start of the list

method : public : Rewind() ~ Nil

Size

Size of list

method : public : Size() ~ Int
Return
TypeDescription
Intsize of list