Struct ReadOnlyPartitionedSet<T>
- Namespace
- Jitter2.DataStructures
- Assembly
- Jitter2.dll
A read-only wrapper around PartitionedSet<T>.
public readonly struct ReadOnlyPartitionedSet<T> : IEnumerable<T>, IEnumerable where T : class, IPartitionedSetIndex
Type Parameters
TThe type of elements in the set.
- Implements
-
IEnumerable<T>
- Inherited Members
- Extension Methods
Constructors
ReadOnlyPartitionedSet(PartitionedSet<T>)
A read-only wrapper around PartitionedSet<T>.
public ReadOnlyPartitionedSet(PartitionedSet<T> partitionedSet)
Parameters
partitionedSetPartitionedSet<T>
Properties
Active
Returns a read-only span of the active elements in the set.
public ReadOnlySpan<T> Active { get; }
Property Value
- ReadOnlySpan<T>
ActiveCount
Gets the number of active elements.
public int ActiveCount { get; }
Property Value
Count
Gets the total number of elements.
public int Count { get; }
Property Value
Elements
Returns a read-only span of all elements in the set.
public ReadOnlySpan<T> Elements { get; }
Property Value
- ReadOnlySpan<T>
Inactive
Returns a read-only span of the inactive elements in the set.
public ReadOnlySpan<T> Inactive { get; }
Property Value
- ReadOnlySpan<T>
this[int]
Gets the element at the specified index.
public T this[int i] { get; }
Parameters
iint
Property Value
- T
Methods
Contains(T)
Determines whether the set contains the specified element.
public bool Contains(T element)
Parameters
elementT
Returns
GetEnumerator()
public PartitionedSet<T>.Enumerator GetEnumerator()
Returns
IsActive(T)
Determines whether the specified element is in the active partition.
public bool IsActive(T element)
Parameters
elementT