Struct BitSet32
- Namespace
- Lime
- Assembly
- Lime.dll
Representation of 32-bit array of bit flags.
public struct BitSet32 : IEquatable<BitSet32>
- Implements
- Inherited Members
Constructors
BitSet32(uint)
public BitSet32(uint value)
Parameters
value
uint
Fields
Empty
Returns 0x00000000 (all bits are 0).
public static readonly BitSet32 Empty
Field Value
Full
Returns 0xffffffff (all bits are 1).
public static readonly BitSet32 Full
Field Value
Value
Uint that is used for array representation.
[YuzuMember("0")]
public uint Value
Field Value
Properties
Count
public int Count { get; }
Property Value
this[int]
public bool this[int bit] { get; set; }
Parameters
bit
intBit index (0 - 31).
Property Value
Methods
All()
Returns true if all bits are 1.
public bool All()
Returns
Any()
Returns true if any bit is 1.
public bool Any()
Returns
Equals(BitSet32)
Indicates whether the current object is equal to another object of the same type.
public bool Equals(BitSet32 other)
Parameters
other
BitSet32An object to compare with this object.
Returns
Equals(object)
Indicates whether this instance and a specified object are equal.
public override bool Equals(object obj)
Parameters
obj
objectThe object to compare with the current instance.
Returns
- bool
true if
obj
and this instance are the same type and represent the same value; otherwise, false.
GetHashCode()
Returns the hash code for this instance.
public override int GetHashCode()
Returns
- int
A 32-bit signed integer that is the hash code for this instance.
ToString()
Returns the string representation of this BitSet32 as sequence of "0" and "1" (from 32 bit to 1 bit). Zeroes on the left are trimmed.
public override string ToString()
Returns
Operators
operator ==(BitSet32, BitSet32)
public static bool operator ==(BitSet32 lhs, BitSet32 rhs)
Parameters
Returns
operator !=(BitSet32, BitSet32)
public static bool operator !=(BitSet32 lhs, BitSet32 rhs)