MultiList<T>

public class MultiList<T>
Provides access to a sequential collection of lists.
TType to store in lists.

Constructors

MultiList

#
Create a new blank multi-list.
public MultiList()

MultiList

#
Create a new blank multi-list.
public MultiList(
initialCapacity
Initial capacity for first list.
)

Properties

CurrentCount

#
Gets the total number of items in the current list.
public int CurrentCount { get; }

EmptyLists

#
Gets the total number of empty lists in this multi-list.
public int EmptyLists { get; }

ItemCount

#
Gets the total number of items.
public int ItemCount { get; }

Items

#
Enumerate over all items.
public IEnumerable<T> Items { get; }

ListCount

#
Gets the number of sublists.
public int ListCount { get; }

Lists

#
Enumerate over all lists.
public IEnumerable<List<T>> Lists { get; }

Indexers

this[]

#
Gets the list at the given index.
public List<T> this[
index
List index.
] { get; }
List at index.

Methods

Add

#
Add a new item to the current list.
public void Add(
T
item
Item to add.
)

AddRange

#
Add a collection of items to the current list.
public void AddRange(
items
Items to add.
)

BeginNewList

#
Close the current list and begin a fresh list. If the current list is empty, nothing will happen.
public void BeginNewList()

Flatten

#
Collect all items in all lists and put them into a single list.
public void Flatten()

Posterize

#
Chop all lists into smaller lists with the maximum count.
public void Posterize(
size
Maximum allowed list length.
)

SplitBetween

#
Split lists between specific items.
public void SplitBetween(
Func<T, T, bool>
splittingDelegate
Delegate for determining splitting locations.
)