docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Class XrResultExtensions

    Extension methods for XrResult.

    Inheritance
    object
    XrResultExtensions
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: UnityEngine.XR.OpenXR.NativeTypes
    Assembly: Unity.XR.OpenXR.dll
    Syntax
    public static class XrResultExtensions

    Methods

    IsError(XrResult)

    Indicates whether the XrResult represents an error code.

    Declaration
    public static bool IsError(this XrResult xrResult)
    Parameters
    Type Name Description
    XrResult xrResult

    The XrResult.

    Returns
    Type Description
    bool

    true if the XrResult represents an error code. Otherwise, false.

    IsSuccess(XrResult)

    Indicates whether the XrResult represents a success code, inclusive of Success.

    Declaration
    public static bool IsSuccess(this XrResult xrResult)
    Parameters
    Type Name Description
    XrResult xrResult

    The XrResult.

    Returns
    Type Description
    bool

    true if the XrResult represents a success code. Otherwise, false.

    IsUnqualifiedSuccess(XrResult)

    Indicates whether the XrResult represents an unqualified success, ie Success.

    Declaration
    public static bool IsUnqualifiedSuccess(this XrResult xrResult)
    Parameters
    Type Name Description
    XrResult xrResult

    The XrResult.

    Returns
    Type Description
    bool

    true if the XrResult represents an unqualified success. Otherwise, false.

    In This Article
    Back to top
    Copyright © 2025 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)