← Standard library

Flags

constraint Flags
import Flags from Wax;

Value operations and bit-set manipulation supplied by flags types. Add, Remove, and Toggle return a new value; they do not mutate the receiver.

NumericConstraints.wax:110

Members

GetHashCodemethod

public fn GetHashCode() : uint32

Returns a hash consistent with value equality.

NumericConstraints.wax:114

ToStringmethod

public fn ToString() : string

Returns the value's text representation.

NumericConstraints.wax:118

ToStringBuffermethod

public fn ToStringBuffer(StringBuilder builder) : int32

Appends the text representation and returns the number of UTF-8 bytes appended.

NumericConstraints.wax:122

Equalsmethod

public fn Equals(this other) : bool

Tests value equality.

NumericConstraints.wax:126

CompareTomethod

public fn CompareTo(this other) : int32

Returns negative, zero, or positive for less, equal, or greater.

NumericConstraints.wax:130

HasValuemethod

public fn HasValue(this flags) : bool

Tests whether any supplied flag bit is set.

NumericConstraints.wax:134

HasAllmethod

public fn HasAll(this flags) : bool

Tests whether every supplied flag bit is set; an empty mask succeeds.

NumericConstraints.wax:138

Addmethod

public fn Add(this flags) : this

Returns the union with the supplied flag bits.

NumericConstraints.wax:142

Removemethod

public fn Remove(this flags) : this

Returns a value with the supplied flag bits cleared.

NumericConstraints.wax:146

Togglemethod

public fn Toggle(this flags) : this

Returns a value with the supplied flag bits inverted.

NumericConstraints.wax:150