Mojo struct
TraceCategory
@register_passable(trivial)
struct TraceCategory
An enum-like struct specifying the type of tracing to perform.
Fields
- value (
Int
): The integer value representing the trace category. Used for bitwise operations when determining if profiling is enabled for a specific category.
Implemented traits
AnyType
,
Copyable
,
EqualityComparable
,
ExplicitlyCopyable
,
Intable
,
Movable
,
UnknownDestructibility
Aliases
ASYNCRT
alias ASYNCRT = TraceCategory(1)
Kernel
alias Kernel = TraceCategory(3)
MAX
alias MAX = TraceCategory(4)
MEM
alias MEM = TraceCategory(2)
OTHER
alias OTHER = TraceCategory(0)
Methods
__eq__
__eq__(self, rhs: Self) -> Bool
Compares for equality.
Args:
- rhs (
Self
): The value to compare.
Returns:
True if they are equal.
__ne__
__ne__(self, rhs: Self) -> Bool
Compares for inequality.
Args:
- rhs (
Self
): The value to compare.
Returns:
True if they are not equal.
__is__
__is__(self, rhs: Self) -> Bool
Compares for equality.
Args:
- rhs (
Self
): The value to compare.
Returns:
True if they are equal.
__isnot__
__isnot__(self, rhs: Self) -> Bool
Compares for inequality.
Args:
- rhs (
Self
): The value to compare.
Returns:
True if they are not equal.
__int__
__int__(self) -> Int
Converts the trace category to an integer.
Returns:
The integer value of the trace category.
Was this page helpful?
Thank you! We'll create more content like this.
Thank you for helping us improve!