IListableCollection - acadet/ludivine GitHub Wiki

IListableCollection<T>
|> ISortableCollection<T>
    |> ICollection<T>

Interface for listable collections, whatever complexity they have (ArrayList, SortedList etc.). T types elements.

Current implementations

References

Methods

add(value : T) : void

Adds new item to list.

Parameters

value Value

getAt(index : number) : T

Gets element at specified index. Throws error if index is unbound.

Parameters

index Index

getLength() : number

Gets length of list.

remove(value : T) : void

Removes element from list. If element is in multiple times, removes only once.

Parameters

value Value

removeAt(index : number) : void

Removes element at specified index. Throws error if index is unbound.

Parameters

index Index

removeIf(func : Func<T, boolean>) : void

Removes all elements matching provided condition.

Parameters

func Returns true if element has to be removed

⚠️ **GitHub.com Fallback** ⚠️