DTGItemState
public enum DTGItemState : Int
Item state.
-
Item was just added, no metadata is available except for the id and the URL.
Declaration
Swift
case new
-
Item’s metadata was loaded. Tracks information is available.
Declaration
Swift
case metadataLoaded
-
Item download is in progress.
Declaration
Swift
case inProgress
-
Item is paused by the app/user.
Declaration
Swift
case paused
-
Item has finished downloading and processing.
Declaration
Swift
case completed
-
Item download has failed (fatal error cannot use this item again).
Declaration
Swift
case failed
-
Item download was interrupted (can be caused by error that we can recover from)
For example: when we can call start item again after this state.
Declaration
Swift
case interrupted
-
Item is removed. This is only a temporary state, as the item is actually removed.
Declaration
Swift
case removed
-
Item had a failure related to db access. If this state is sent make sure to save the id of the item to later try again.
Attention
It is important to keep this state seperatly because usually this will happen in a rare case where the device is out of storage and actions can’t be made, meaning we cannot update item progress and its real state will be the last state that is was, for example for an item in the middle of a download that last state will bein progress
. if the storage will be available again we recommand removing the item and starting it again.Declaration
Swift
case dbFailure
-
Undocumented
Declaration
Swift
public func asString() -> String