Class Collector<T>
Lightweight accumulation container used by Vista collection callbacks and paired runtime data lists.
public class Collector<T> : IEnumerable<T>, IEnumerable
Type Parameters
T
- Inheritance
-
Collector<T>
- Implements
-
IEnumerable<T>
- Inherited Members
Remarks
This type appears in two main patterns: event-driven discovery flows such as tile, biome, or version collection, and paired internal storage inside Core.BiomeData. Items are stored in insertion order and duplicates are allowed while collecting; distinct filtering only happens when exporting with ToList() or ToArray().
Constructors
- Collector()
Creates an empty collector.
Properties
- Count
Number of items currently stored in the collector, including duplicates.
Methods
- Add(T)
Appends an item to the collector.
- At(int)
Returns the item stored at a zero-based index.
- Clear()
Removes all currently collected items.
- Contains(T)
Determines whether the collector currently contains a specific item.
- GetEnumerator()
Returns an enumerator over the raw collected items in insertion order.
- IndexOf(T)
Returns the index of the first occurrence of an item in the collector.
- ToArray()
Exports the collected items as a distinct array.
- ToList()
Exports the collected items as a distinct list.