CLASS

# RoomleDataManager

Contents

  • Properties
    • delegate
  • Methods
    • syncCatalogs(type:)
    • isSyncing()
    • getCatalogs(resolvedConnections:)
    • getCatalog(with:resolvedConnections:)
    • getProductCatalogCategory(resolvedConnections:)
    • getRoomCatalogCategory(resolvedConnections:)

Can access all possible catalog based data like catalogs, categories and items.

# Properties

# delegate

Delegate which is called, if a catalog sync is finished for example.

# Methods

# syncCatalogs(type:)

Start a new catalog sync with given type to query all visible catalogs for your tenant. If no type is given .quick will be default sync type.

  • parameter type: type which decides which elements are going to be synced.

# isSyncing()

Property determines if a catalog sync is already running

# getCatalogs(resolvedConnections:)

Get all synced catalogs.

IMPORTANT if no resolvedConnection is set - .none will be used, which means that no items and categories are associated to returned catalogs. This is made in order to save performance and memory.

  • parameter resolvedConnections: describes which connections should be resolved

# getCatalog(with:resolvedConnections:)

Returns a catalog based on given id. Catalog will have all associated items and categories attached, if no resolvedConnection is set - .all will be used.

  • parameter id: id of the catalog which will be returned, if found
  • parameter resolvedConnections: describes which connections should be resolved

# getProductCatalogCategory(resolvedConnections:)

Returns "products" category if it already got synced. If no resolvedConnection is set - .all will be used.

  • parameter resolvedConnections: describes which connections should be resolved

# getRoomCatalogCategory(resolvedConnections:)

Returns "rooms" category if it already got synced. If no resolvedConnection is set - .all will be used.

  • parameter resolvedConnections: describes which connections should be resolved