GH_Chunk.ChunkKeyedCollection

References
Represents a collection of chunks with associated IDs

Constructors

ChunkKeyedCollection

#
public ChunkKeyedCollection()
Create a new collection.

Properties

Count

#
public int Count { get; }
Returns the amount in the collection.

Methods

Add

#
public void Add(GH_Chunk chunk)
Adds a new chunk.
chunk (GH_Chunk)The chunk to be added.

Clear

#
public void Clear()
Removes all chunks from the collection.

GetEnumerator

#
public IEnumerator<GH_Chunk> GetEnumerator()
Gets an enumerator that iterates over all chunks in the collection.
The enumerator.

Remove

#
public bool Remove(GH_Chunk chunk)
Removes a chunk.
chunk (GH_Chunk)The chunk to be removed.
True if the operation was successful; false otherwise.

Remove

#
public bool Remove(ID id)
Removes an ID.
id (ID)The ID to be removed.
True if the operation was successful; false otherwise.
Explicit

IEnumerable.GetEnumerator

#
IEnumerator IEnumerable.GetEnumerator()

TryGetValue

#
public bool TryGetValue(ID id, out GH_Chunk chunk)
Try and find the chunk that belongs to a given ID.
id (ID)ID to look for.
chunk (out GH_Chunk)Chunk result.
True is a chunk was found, false if otherwise.