Skip to main content

Mojo struct

ThreadRole

struct ThreadRole

Implemented traits

AnyType, Copyable, ImplicitlyCopyable, Movable, Stringable, UnknownDestructibility, Writable

Aliases

__copyinit__is_trivial

alias __copyinit__is_trivial = UInt8.__copyinit__is_trivial

__del__is_trivial

alias __del__is_trivial = UInt8.__del__is_trivial

__moveinit__is_trivial

alias __moveinit__is_trivial = UInt8.__moveinit__is_trivial

CONSUMER

alias CONSUMER = ThreadRole(1)

PRODUCER

alias PRODUCER = ThreadRole(0)

PRODUCER_CONSUMER

alias PRODUCER_CONSUMER = ThreadRole(2)

Methods

__eq__

__eq__(self, other: Self) -> Bool

Returns:

Bool

__ne__

__ne__(self, other: Self) -> Bool

Returns:

Bool

__is__

__is__(self, other: Self) -> Bool

Returns:

Bool

__isnot__

__isnot__(self, other: Self) -> Bool

Returns:

Bool

__str__

__str__(self) -> String

Returns the string representation of this algorithm.

Returns:

String: String: A human-readable string representation of the algorithm.

write_to

write_to[W: Writer](self, mut writer: W)

Was this page helpful?