{!See https://docs.google.com/document/d/1takg_GmIBBKKTj-GHZCwzxohpQz7Bhekivkk72kYMtE/edit for reference implementation of OneTrust, dataLayer and GTM} {!OneTrust Cookies Consent} {!OneTrust Cookies Consent end} {!dataLayer initialization push} {!dataLayer initialization push end} {!Google Tag Manager} {!Google Tag Manager end} Method GetLocatorInfo | Addressables | 1.21.17
docs.unity3d.com
"{0}"의 검색 결과

    목차 표시/숨기기

    Method GetLocatorInfo

    GetLocatorInfo(string)

    Given the Id of an IResourceLocator, get the relevant content catalog data associated with it.

    선언
    public static ResourceLocatorInfo GetLocatorInfo(string locatorId)
    파라미터
    타입 이름 설명
    string locatorId

    The identifier of an IResourceLocator used to retrieve content catalog data.

    반환
    타입 설명
    ResourceLocatorInfo

    Container for content catalog data pertaining to the IResourceLocator object.

    참고

    Retrieves the content catalog data associated with the specified IResourceLocator id. The catalog data is stored as a ResourceLocatorInfo object.

    예

    The example below uses the identifiers of the resource locators loaded during Addressables initialization process to retrieve catalog data.

    IEnumerator UsingGetLocatorInfoSampleId()
    {
        yield return Addressables.InitializeAsync();
        IEnumerable<IResourceLocator> resourceLocators = Addressables.ResourceLocators;
        foreach (IResourceLocator locator in resourceLocators)
        {
            // Call GetLocatorInfo using the locator id
            ResourceLocatorInfo locatorInfo = Addressables.GetLocatorInfo(locator.LocatorId);
            if (locatorInfo != null && locatorInfo.CatalogLocation != null)
            {
                if (locatorInfo.CanUpdateContent)
                    Debug.Log($"Locator {locator.LocatorId} was loaded from an UPDATABLE catalog with internal id : {locatorInfo.CatalogLocation.InternalId}");
                else
                    Debug.Log($"Locator {locator.LocatorId} was loaded from an NON-UPDATABLE catalog with internal id : {locatorInfo.CatalogLocation.InternalId}");
            }
            else
            {
                Debug.Log($"Locator {locator.LocatorId} is not associated with a catalog");
            }
        }
    }

    GetLocatorInfo(IResourceLocator)

    Given an IResourceLocator, get the relevant content catalog data associated with it.

    선언
    public static ResourceLocatorInfo GetLocatorInfo(IResourceLocator locator)
    파라미터
    타입 이름 설명
    IResourceLocator locator

    The resource locator you want to get content catalog data for.

    반환
    타입 설명
    ResourceLocatorInfo

    Container for content catalog data pertaining to the IResourceLocator object.

    문서 개요
    맨 위로
    Copyright © 2023 Unity Technologies — 상표 및 이용약관
    • 법률정보
    • 개인정보처리방침
    • 쿠키
    • 내 개인정보 판매 금지
    • Your Privacy Choices (Cookie Settings)