# Module: OfflineController

Provides access to offline stream recording and playback functionality. This module can be accessed using the MediaPlayer API getOfflineController()

Source:
  - offline/controllers/OfflineController.js, line 41

### Methods

#### <static> loadRecordsFromStorage()

  Loads records from storage
  This methods has to be called first, to be sure that all downloads have been loaded

  Source:
    - offline/controllers/OfflineController.js, line 210

  ##### Returns:

  asynchronously resolved

  Type
    Promise

#### createRecord(manifestURL)

  Create a new content record in storage and download manifest from url

  ##### Parameters:

  Name | Type | Description
  --- | --- | ---
  `manifestURL` | string | the content manifest url

  Source:
    - offline/controllers/OfflineController.js, line 254

  ##### Returns:

  asynchronously resolved with record identifier

  Type
    Promise

#### deleteRecord(id)

  Deletes a record from storage

  ##### Parameters:

  Name | Type | Description
  --- | --- | ---
  `id` | string | record identifier

  Source:
    - offline/controllers/OfflineController.js, line 324

#### getAllRecords()

  Get all records from storage

  Source:
    - offline/controllers/OfflineController.js, line 232

  ##### Returns:

  asynchronously resolved with records

  Type
    Promise

#### getRecordProgression(id)

  Get download progression of a record

  ##### Parameters:

  Name | Type | Description
  --- | --- | ---
  `id` | string | record identifier

  Source:
    - offline/controllers/OfflineController.js, line 339

  ##### Returns:

  percentage progression

  Type
    number

#### resetRecords()

  Reset all records

  Source:
    - offline/controllers/OfflineController.js, line 352

#### resumeRecord(id)

  Resume downloading of the record

  ##### Parameters:

  Name | Type | Description
  --- | --- | ---
  `id` | string | record identifier

  Source:
    - offline/controllers/OfflineController.js, line 310

#### startRecord(id, mediaInfos)

  Start downloading the record with selected tracks representations

  ##### Parameters:

  Name | Type | Description
  --- | --- | ---
  `id` | string | record identifier
  `mediaInfos` | Array.<MediaInfo> | the selected tracks representations

  Source:
    - offline/controllers/OfflineController.js, line 282

#### stopRecord(id)

  Stop downloading of the record

  ##### Parameters:

  Name | Type | Description
  --- | --- | ---
  `id` | string | record identifier

  Source:
    - offline/controllers/OfflineController.js, line 296

#### Search results