Skip to content

Game.EndFrameBarrier

Assembly:
Not specified in source. This file defines a compiler/metadata attribute; in practice this kind of type is embedded into the assembly that supplies it (or into core libraries like mscorlib/System.Private.CoreLib) and references Microsoft.CodeAnalysis via an embedded attribute.

Namespace: System.Runtime.CompilerServices

Type:
internal sealed class NullableContextAttribute : Attribute

Base:
System.Attribute

Summary:
Represents a compiler-provided attribute that conveys nullable-context information (a single byte flag) for types, methods, delegates and other targets. The attribute is marked as compiler-generated and embedded (Microsoft.CodeAnalysis.Embedded). It is used to record the nullable-state that the compiler applied at the declaration site so that consumers (tools, analyzers, or other compilers) can interpret nullable annotations/warnings correctly.

The original source declares: - [CompilerGenerated] - [Microsoft.CodeAnalysis.Embedded] - [AttributeUsage(AttributeTargets.Class | AttributeTargets.Struct | AttributeTargets.Method | AttributeTargets.Interface | AttributeTargets.Delegate, AllowMultiple = false, Inherited = false)] and defines a single readonly byte field Flag and a constructor accepting that byte.


Fields

  • private System.Diagnostics.Stopwatch m_Stopwatch
    This class does not declare m_Stopwatch. The provided source file describes a simple attribute; there is no Stopwatch field. The template field here is unrelated to NullableContextAttribute.

  • private Unity.Jobs.JobHandle <producerHandle>k__BackingField
    This class does not declare a producerHandle or any Unity.Jobs.JobHandle backing field. The template field here is unrelated to NullableContextAttribute.

  • public readonly byte Flag
    The actual field declared by NullableContextAttribute. It stores the byte value passed to the attribute at construction which encodes the nullable context state (the exact meaning of numeric values depends on compiler/metadata conventions; typically it signals whether nullable annotations/warnings are enabled or disabled in that context).

Properties

  • public Unity.Jobs.JobHandle producerHandle { get; private set }
    NullableContextAttribute does not declare this property. The template property is unrelated. There are no properties in the provided attribute.

Constructors

  • public EndFrameBarrier()
    Not applicable. The template constructor shown here (EndFrameBarrier) is unrelated to this source file.

  • public NullableContextAttribute(byte P_0)
    The actual constructor present in the source. It accepts a single byte parameter (P_0) and assigns it to the readonly Flag field.

Methods

  • protected virtual OnCreate() : System.Void
    NullableContextAttribute declares no methods beyond the constructor; there are no OnCreate or similar lifecycle methods. The template method is unrelated.

Usage Example

// Applying the attribute to indicate a compiler nullable-context state (example only)
[System.Runtime.CompilerServices.NullableContextAttribute(1)]
internal class ExampleClass
{
    // The numeric value (1 above) encodes how the compiler interpreted nullable annotations/warnings
}

Notes: - This attribute is intended to be used by the compiler and tooling to annotate metadata about nullable reference types; you generally do not need to create or consume it manually in mods unless you are emitting or manipulating compiled metadata. - The code also includes attribute decorations: [CompilerGenerated], [Microsoft.CodeAnalysis.Embedded], and an AttributeUsage restricting targets and disallowing multiple usage/inheritance.