docs.unity.cn
    Show / Hide Table of Contents

    Struct EnabledRefRO<T>

    Stores a safe reference to a read-only component enable bit.

    Namespace: Unity.Entities
    Syntax
    [GenerateTestsForBurstCompatibility(GenericTypeArguments = new Type[]{typeof(BurstCompatibleEnableableComponent)}, RequiredUnityDefine = "ENABLE_UNITY_COLLECTIONS_CHECKS")]
    public readonly struct EnabledRefRO<T> : IQueryTypeParameter where T : struct, IEnableableComponent
    Type Parameters
    Name Description
    T

    Type of enabled component

    Remarks

    Do not store outside of stack

    Constructors

    Name Description
    EnabledRefRO(SafeBitRef)

    Constructor for read-only enable reference to enableable component. This is typically used by generated code inside of Aspects.

    Properties

    Name Description
    IsValid

    Property that returns true if the reference is valid, false otherwise.

    Null

    Null value for this reference.

    ValueRO

    Property to get enabled value of this reference (true if enabled, false otherwise).

    Back to top Copyright © 2023 Unity Technologies — Terms of use
    Generated by DocFX
    on Wednesday, September 20, 2023