docs.unity3d.com
    Show / Hide Table of Contents

    Class AdaptivePerformanceLoaderHelper

    Adaptive Performance Loader abstract subclass used as a base class for specific provider implementations. Class provides some helper logic that can be used to handle subsystem handling in a typesafe manner, reducing potential boilerplate code.

    Inheritance
    Object
    UnityEngine.Object
    UnityEngine.ScriptableObject
    AdaptivePerformanceLoader
    AdaptivePerformanceLoaderHelper
    FailToLoadLoader
    SimulatorProviderLoader
    TestLoaderBase
    StandaloneLoader
    Inherited Members
    AdaptivePerformanceLoader.Initialized
    AdaptivePerformanceLoader.Running
    AdaptivePerformanceLoader.Initialize()
    AdaptivePerformanceLoader.Start()
    AdaptivePerformanceLoader.Stop()
    AdaptivePerformanceLoader.GetDefaultSubsystem()
    AdaptivePerformanceLoader.GetSettings()
    UnityEngine.ScriptableObject.SetDirty()
    UnityEngine.ScriptableObject.CreateInstance(System.String)
    UnityEngine.ScriptableObject.CreateInstance(System.Type)
    UnityEngine.ScriptableObject.CreateInstance<T>()
    UnityEngine.Object.GetInstanceID()
    UnityEngine.Object.GetHashCode()
    UnityEngine.Object.Equals(System.Object)
    UnityEngine.Object.Instantiate(UnityEngine.Object, UnityEngine.Vector3, UnityEngine.Quaternion)
    UnityEngine.Object.Instantiate(UnityEngine.Object, UnityEngine.Vector3, UnityEngine.Quaternion, UnityEngine.Transform)
    UnityEngine.Object.Instantiate(UnityEngine.Object)
    UnityEngine.Object.Instantiate(UnityEngine.Object, UnityEngine.Transform)
    UnityEngine.Object.Instantiate(UnityEngine.Object, UnityEngine.Transform, System.Boolean)
    UnityEngine.Object.Instantiate<T>(T)
    UnityEngine.Object.Instantiate<T>(T, UnityEngine.Vector3, UnityEngine.Quaternion)
    UnityEngine.Object.Instantiate<T>(T, UnityEngine.Vector3, UnityEngine.Quaternion, UnityEngine.Transform)
    UnityEngine.Object.Instantiate<T>(T, UnityEngine.Transform)
    UnityEngine.Object.Instantiate<T>(T, UnityEngine.Transform, System.Boolean)
    UnityEngine.Object.Destroy(UnityEngine.Object, System.Single)
    UnityEngine.Object.Destroy(UnityEngine.Object)
    UnityEngine.Object.DestroyImmediate(UnityEngine.Object, System.Boolean)
    UnityEngine.Object.DestroyImmediate(UnityEngine.Object)
    UnityEngine.Object.FindObjectsOfType(System.Type)
    UnityEngine.Object.FindObjectsOfType(System.Type, System.Boolean)
    UnityEngine.Object.DontDestroyOnLoad(UnityEngine.Object)
    UnityEngine.Object.DestroyObject(UnityEngine.Object, System.Single)
    UnityEngine.Object.DestroyObject(UnityEngine.Object)
    UnityEngine.Object.FindSceneObjectsOfType(System.Type)
    UnityEngine.Object.FindObjectsOfTypeIncludingAssets(System.Type)
    UnityEngine.Object.FindObjectsOfType<T>()
    UnityEngine.Object.FindObjectsOfType<T>(System.Boolean)
    UnityEngine.Object.FindObjectOfType<T>()
    UnityEngine.Object.FindObjectOfType<T>(System.Boolean)
    UnityEngine.Object.FindObjectsOfTypeAll(System.Type)
    UnityEngine.Object.FindObjectOfType(System.Type)
    UnityEngine.Object.FindObjectOfType(System.Type, System.Boolean)
    UnityEngine.Object.ToString()
    UnityEngine.Object.name
    UnityEngine.Object.hideFlags
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetType()
    Object.MemberwiseClone()
    Namespace: UnityEngine.AdaptivePerformance
    Syntax
    public abstract class AdaptivePerformanceLoaderHelper : AdaptivePerformanceLoader

    Fields

    m_SubsystemInstanceMap

    Map of loaded susbsystems. Used so Unity doesn't always have to call AdaptivePerformanceManger and do a manual search to find the instance it loaded.

    Declaration
    protected Dictionary<Type, ISubsystem> m_SubsystemInstanceMap
    Field Value
    Type Description
    Dictionary<Type, UnityEngine.ISubsystem>

    Methods

    CreateSubsystem<TDescriptor, TSubsystem>(List<TDescriptor>, String)

    Creates a subsystem with a given list of descriptors and a specific subsystem id.

    Declaration
    protected void CreateSubsystem<TDescriptor, TSubsystem>(List<TDescriptor> descriptors, string id)
        where TDescriptor : ISubsystemDescriptor where TSubsystem : ISubsystem
    Parameters
    Type Name Description
    List<TDescriptor> descriptors

    List of TDescriptor instances to use for subsystem matching.

    String id

    The identifier key of the particualr subsystem implementation being requested.

    Type Parameters
    Name Description
    TDescriptor

    The descriptor type being passed in.

    TSubsystem

    The subsystem type being requested.

    Deinitialize()

    Override of Deinitialize() to provide for clearing the instance map.

    If you override Deinitialize() in your subclass, you must call the base implementation to allow the instance map tp be cleaned up correctly.

    Declaration
    public override bool Deinitialize()
    Returns
    Type Description
    Boolean

    True if de-initialization was successful.

    Overrides
    AdaptivePerformanceLoader.Deinitialize()

    DestroySubsystem<T>()

    Destroy a subsystem instance of a given type. Subsystem is assumed to already be loaded from a previous call to CreateSubsystem.

    Declaration
    protected void DestroySubsystem<T>()
        where T : class, ISubsystem
    Type Parameters
    Name Description
    T

    A subclass of UnityEngine.ISubsystem

    GetLoadedSubsystem<T>()

    Gets the loaded subsystem of the specified type. This is implementation-specific, because implementations contain data on what they have loaded and how best to get it.

    Declaration
    public override T GetLoadedSubsystem<T>()
        where T : class, ISubsystem
    Returns
    Type Description
    T

    The loaded subsystem, or null if no subsystem found.

    Type Parameters
    Name Description
    T

    Type of the subsystem to get.

    Overrides
    AdaptivePerformanceLoader.GetLoadedSubsystem<T>()

    StartSubsystem<T>()

    Start a subsystem instance of a given type. Subsystem is assumed to already be loaded from a previous call to CreateSubsystem.

    Declaration
    protected void StartSubsystem<T>()
        where T : class, ISubsystem
    Type Parameters
    Name Description
    T

    A subclass of UnityEngine.ISubsystem

    StopSubsystem<T>()

    Stop a subsystem instance of a given type. Subsystem is assumed to already be loaded from a previous call to CreateSubsystem.

    Declaration
    protected void StopSubsystem<T>()
        where T : class, ISubsystem
    Type Parameters
    Name Description
    T

    A subclass of UnityEngine.ISubsystem

    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023