using System; using System.Collections.Generic; using UnityEngine.AddressableAssets.ResourceLocators; using UnityEngine.Networking; using UnityEngine.ResourceManagement.Util; using UnityEngine.Serialization; namespace UnityEngine.AddressableAssets.Initialization { /// /// Runtime data that is used to initialize the Addressables system. /// [Serializable] public class ResourceManagerRuntimeData { /// /// Address of the contained catalogs. /// public const string kCatalogAddress = "AddressablesMainContentCatalog"; [SerializeField] string m_buildTarget; /// /// The name of the build target that this data was prepared for. /// public string BuildTarget { get { return m_buildTarget; } set { m_buildTarget = value; } } [FormerlySerializedAs("m_settingsHash")] [SerializeField] string m_SettingsHash; /// /// The hash of the settings that generated this runtime data. /// public string SettingsHash { get { return m_SettingsHash; } set { m_SettingsHash = value; } } [FormerlySerializedAs("m_catalogLocations")] [SerializeField] List m_CatalogLocations = new List(); /// /// List of catalog locations to download in order (try remote first, then local) /// public List CatalogLocations { get { return m_CatalogLocations; } } [FormerlySerializedAs("m_profileEvents")] [SerializeField] bool m_ProfileEvents; /// /// Flag to control whether the ResourceManager sends profiler events. /// public bool ProfileEvents { get { return m_ProfileEvents; } set { m_ProfileEvents = value; } } [FormerlySerializedAs("m_logResourceManagerExceptions")] [SerializeField] bool m_LogResourceManagerExceptions = true; /// /// When enabled, the Addressables.ResourceManager.ExceptionHandler is set to (op, ex) => Debug.LogException(ex); /// public bool LogResourceManagerExceptions { get { return m_LogResourceManagerExceptions; } set { m_LogResourceManagerExceptions = value; } } [FormerlySerializedAs("m_extraInitializationData")] [SerializeField] List m_ExtraInitializationData = new List(); /// /// The list of initialization data. These objects will get deserialized and initialized during the Addressables initialization process. This happens after resource providers have been set up but before any catalogs are loaded. /// public List InitializationObjects { get { return m_ExtraInitializationData; } } [SerializeField] SerializedType m_CertificateHandlerType; /// /// The type of CertificateHandler to use for this provider. /// public Type CertificateHandlerType { get { return m_CertificateHandlerType.Value; } set { m_CertificateHandlerType.Value = value; } } } }