using UnityEngine; namespace UnityEngine.Perception.Randomization { /// /// Derive this class to load Unity assets from a specific location /// public abstract class AssetSourceLocation { /// /// The number of assets available at this location /// public abstract int count { get; } /// /// Execute setup steps before accessing assets at this location /// /// The asset role that will be used to preprocess assets from this location /// The type of assets that will be loaded from this location public abstract void Initialize(AssetRole assetRole) where T : Object; /// /// Unload all assets loaded from this location /// public abstract void ReleaseAssets(); /// /// Retrieves an asset from this location using the provided index /// /// The index to load the asset from /// The type of asset to load /// The loaded asset public abstract T LoadAsset(int index) where T : Object; } }