ItemResourceCache Class

ArcGISVectorTiledLayer."> ItemResourceCache Class | ArcGISQtCpp
  • ItemResourceCache
  • class Esri::ArcGISRuntime::ItemResourceCache

    An object containing information on offline resources typically associated with a custom style for an ArcGISVectorTiledLayer. More...

    Header: #include <ItemResourceCache.h>
    Since: Esri::ArcGISRuntime 100.2
    Inherits: Esri::ArcGISRuntime::Object and Esri::ArcGISRuntime::Loadable

    Public Functions

    ItemResourceCache(const QString &path, QObject *parent = nullptr)
    virtual ~ItemResourceCache() override
    Esri::ArcGISRuntime::LocalItem *item() const
    QString path() const

    Reimplemented Public Functions

    virtual void cancelLoad() override
    virtual void load() override
    virtual Esri::ArcGISRuntime::Error loadError() const override
    virtual Esri::ArcGISRuntime::LoadStatus loadStatus() const override
    virtual void retryLoad() override

    Signals

    void doneLoading(const Esri::ArcGISRuntime::Error &loadError)
    void loadStatusChanged(Esri::ArcGISRuntime::LoadStatus loadStatus)

    Detailed Description

    An object containing information about resources associated with an ArcGISVectorTiledLayer. For example, a vector tile layer has style resources such as fonts, sprites, etc.

    Member Function Documentation

    [explicit] ItemResourceCache::ItemResourceCache(const QString &path, QObject *parent = nullptr)

    Creates an instance of this object with a path to a directory containing ItemResourceCache.

    • path - path.
    • parent - The optional parent QObject.

    [override virtual] ItemResourceCache::~ItemResourceCache()

    Destructor

    [override virtual] void ItemResourceCache::cancelLoad()

    Reimplements: Loadable::cancelLoad().

    Cancels loading metadata for the object.

    Cancels loading the metadata if the object is loading.

    See Loadable.

    [signal] void ItemResourceCache::doneLoading(const Esri::ArcGISRuntime::Error &loadError)

    Signal emitted when this object is done loading.

    • loadError - Details about any error that may have occurred.

    If there is a load error, it will also be emitted on the errorOccurred signal.

    See also Loadable and Object.

    Esri::ArcGISRuntime::LocalItem *ItemResourceCache::item() const

    Returns the local item containing this item resource cache's thumbnail and metadata.

    This property can be a nullptr if the LocalItem is not present within the ItemResourceCache directory. If the ItemResourceCache was taken offline using ExportVectorTilesTask or OfflineMapTask, the LocalItem will be populated from the online PortalItem. If the ItemResourceCache was created inside a MobileMapPackage authored from ArcGIS Pro, then this property will return a nullptr.

    [override virtual] void ItemResourceCache::load()

    Reimplements: Loadable::load().

    Loads the metadata for the object asynchronously.

    Loads the metadata if the object is not loaded.

    See Loadable.

    [override virtual] Esri::ArcGISRuntime::Error ItemResourceCache::loadError() const

    Reimplements: Loadable::loadError() const.

    Returns the load error.

    See Loadable.

    See also Error.

    [override virtual] Esri::ArcGISRuntime::LoadStatus ItemResourceCache::loadStatus() const

    Reimplements: Loadable::loadStatus() const.

    Returns the load status.

    See Loadable.

    See also LoadStatus.

    [signal] void ItemResourceCache::loadStatusChanged(Esri::ArcGISRuntime::LoadStatus loadStatus)

    loadStatus See Loadable.

    QString ItemResourceCache::path() const

    Returns the path to the on-disk location containing this item resource cache.

    The path can be a directory on disk that contains the ItemResourceCache. Alternatively, if the ItemResourceCache was loaded from a package file, such as a MobileMapPackage, the path is to the package.

    [override virtual] void ItemResourceCache::retryLoad()

    Reimplements: Loadable::retryLoad().

    Loads or retries loading metadata for the object asynchronously.

    Will retry loading the metadata if the object is failed to load. Will load the object if it is not loaded. Will not retry to load the object if the object is loaded. Will always call the done loading if this is called.

    See Loadable.

    Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.