PVR recording methods
To transfer available recordings of the PVR backend and to allow possible playback.
More...
|
virtual PVR_ERROR | kodi::addon::CInstancePVRClient::GetRecordingsAmount (bool deleted, int &amount) |
| To get amount of recording present on backend.
|
|
virtual PVR_ERROR | kodi::addon::CInstancePVRClient::GetRecordings (bool deleted, kodi::addon::PVRRecordingsResultSet &results) |
| Request the list of all recordings from the backend, if supported.
|
|
virtual PVR_ERROR | kodi::addon::CInstancePVRClient::DeleteRecording (const kodi::addon::PVRRecording &recording) |
| Delete a recording on the backend.
|
|
virtual PVR_ERROR | kodi::addon::CInstancePVRClient::UndeleteRecording (const kodi::addon::PVRRecording &recording) |
| Undelete a recording on the backend.
|
|
virtual PVR_ERROR | kodi::addon::CInstancePVRClient::DeleteAllRecordingsFromTrash () |
| Delete all recordings permanent which in the deleted folder on the backend.
|
|
virtual PVR_ERROR | kodi::addon::CInstancePVRClient::RenameRecording (const kodi::addon::PVRRecording &recording) |
| Rename a recording on the backend.
|
|
virtual PVR_ERROR | kodi::addon::CInstancePVRClient::SetRecordingLifetime (const kodi::addon::PVRRecording &recording) |
| Set the lifetime of a recording on the backend.
|
|
virtual PVR_ERROR | kodi::addon::CInstancePVRClient::SetRecordingPlayCount (const kodi::addon::PVRRecording &recording, int count) |
| Set the play count of a recording on the backend.
|
|
virtual PVR_ERROR | kodi::addon::CInstancePVRClient::SetRecordingLastPlayedPosition (const kodi::addon::PVRRecording &recording, int lastplayedposition) |
| Set the last watched position of a recording on the backend.
|
|
virtual PVR_ERROR | kodi::addon::CInstancePVRClient::GetRecordingLastPlayedPosition (const kodi::addon::PVRRecording &recording, int &position) |
| Retrieve the last watched position of a recording on the backend.
|
|
virtual PVR_ERROR | kodi::addon::CInstancePVRClient::GetRecordingEdl (const kodi::addon::PVRRecording &recording, std::vector< kodi::addon::PVREDLEntry > &edl) |
| Retrieve the edit decision list (EDL) of a recording on the backend.
|
|
virtual PVR_ERROR | kodi::addon::CInstancePVRClient::GetRecordingSize (const kodi::addon::PVRRecording &recording, int64_t &size) |
| Retrieve the size of a recording on the backend.
|
|
virtual PVR_ERROR | kodi::addon::CInstancePVRClient::GetRecordingStreamProperties (const kodi::addon::PVRRecording &recording, std::vector< kodi::addon::PVRStreamProperty > &properties) |
| Get the stream properties for a recording from the backend.
|
|
virtual PVR_ERROR | kodi::addon::CInstancePVRClient::CallRecordingMenuHook (const kodi::addon::PVRMenuhook &menuhook, const kodi::addon::PVRRecording &item) |
| Call one of the recording related menu hooks (if supported).
|
|
void | kodi::addon::CInstancePVRClient::RecordingNotification (const std::string &recordingName, const std::string &fileName, bool on) |
| Callback to Kodi Function
Display a notification in Kodi that a recording started or stopped on the server.
|
|
void | kodi::addon::CInstancePVRClient::TriggerRecordingUpdate () |
| Callback to Kodi Function
Request Kodi to update it's list of recordings.
|
|
PVR recording methods
To transfer available recordings of the PVR backend and to allow possible playback.
Recordings parts in interface:
Copy this to your project and extend with your parts or leave functions complete away where not used or supported.
◆ CallRecordingMenuHook()
Call one of the recording related menu hooks (if supported).
Supported class PVRMenuhook instances have to be added in constructor()
, by calling AddMenuHook() on the callback.
- Parameters
-
[in] | menuhook | The hook to call. |
[in] | item | The selected recording item for which the hook was called. |
- Returns
- PVR_ERROR_NO_ERROR if the hook was called successfully.
The following table contains values that can be set with class PVRMenuhook :
◆ DeleteAllRecordingsFromTrash()
virtual PVR_ERROR kodi::addon::CInstancePVRClient::DeleteAllRecordingsFromTrash |
( |
| ) |
|
|
inlinevirtual |
Delete all recordings permanent which in the deleted folder on the backend.
- Returns
- PVR_ERROR_NO_ERROR if the recordings has been deleted successfully.
◆ DeleteRecording()
Delete a recording on the backend.
- Parameters
-
- Returns
- PVR_ERROR_NO_ERROR if the recording has been deleted successfully.
◆ GetRecordingEdl()
Retrieve the edit decision list (EDL) of a recording on the backend.
- Parameters
-
- Returns
- PVR_ERROR_NO_ERROR if the EDL was successfully read or no EDL exists.
The following table contains values that can be set with class PVREDLEntry :
◆ GetRecordingLastPlayedPosition()
Retrieve the last watched position of a recording on the backend.
- Parameters
-
- Returns
- PVR_ERROR_NO_ERROR if the amount has been fetched successfully.
◆ GetRecordings()
Request the list of all recordings from the backend, if supported.
Recording entries are added to Kodi by calling TransferRecordingEntry() on the callback.
- Parameters
-
- Returns
- PVR_ERROR_NO_ERROR if the recordings have been fetched successfully.
The following table contains values that can be set with class PVRRecording :
Example:
...
{
recording.
SetTitle(
"My recording name");
...
}
...
Definition Recordings.h:39
Definition Recordings.h:638
@ PVR_ERROR_NO_ERROR
0 : No error occurred.
Definition pvr_general.h:38
void SetRecordingId(const std::string &recordingId)
required Unique identifier of the recording on the client.
Definition Recordings.h:112
void SetTitle(const std::string &title)
required The title of this recording.
Definition Recordings.h:125
void Add(const kodi::addon::PVRRecording &tag)
To add and give content from addon to Kodi on related call.
Definition Recordings.h:654
◆ GetRecordingsAmount()
virtual PVR_ERROR kodi::addon::CInstancePVRClient::GetRecordingsAmount |
( |
bool | deleted, |
|
|
int & | amount ) |
|
inlinevirtual |
To get amount of recording present on backend.
- Parameters
-
[in] | deleted | if set return deleted recording (called if supportsRecordingsUndelete set to true) |
[out] | amount | The total amount of recordings on the backend |
- Returns
- PVR_ERROR_NO_ERROR if the amount has been fetched successfully.
◆ GetRecordingSize()
Retrieve the size of a recording on the backend.
- Parameters
-
[in] | recording | The recording to get the size in bytes for. |
[out] | size | The size in bytes of the recording |
- Returns
- PVR_ERROR_NO_ERROR if the recording's size has been set successfully.
◆ GetRecordingStreamProperties()
Get the stream properties for a recording from the backend.
- Parameters
-
[in] | recording | The class PVRRecording to get the stream properties for. |
[out] | properties | The properties required to play the stream. |
- Returns
- PVR_ERROR_NO_ERROR if the stream is available.
- Note
- The value directly related to inputstream must always begin with the name of the associated add-on, e.g.
"inputstream.adaptive.manifest_update_parameter"
.
Example:
...
std::vector<kodi::addon::PVRStreamProperty>& properties)
{
...
properties.emplace_back("inputstream.adaptive.manifest_type", "mpd");
properties.emplace_back("inputstream.adaptive.manifest_update_parameter", "full");
}
...
#define PVR_STREAM_PROPERTY_MIMETYPE
the MIME type of the stream that should be played.
Definition pvr_general.h:311
#define PVR_STREAM_PROPERTY_INPUTSTREAM
To define in stream properties the name of the inputstream add-on that should be used.
Definition pvr_general.h:235
◆ RecordingNotification()
void kodi::addon::CInstancePVRClient::RecordingNotification |
( |
const std::string & | recordingName, |
|
|
const std::string & | fileName, |
|
|
bool | on ) |
|
inline |
Callback to Kodi Function
Display a notification in Kodi that a recording started or stopped on the server.
- Parameters
-
[in] | recordingName | The name of the recording to display |
[in] | fileName | The filename of the recording |
[in] | on | True when recording started, false when it stopped |
◆ RenameRecording()
Rename a recording on the backend.
- Parameters
-
- Returns
- PVR_ERROR_NO_ERROR if the recording has been renamed successfully.
◆ SetRecordingLastPlayedPosition()
Set the last watched position of a recording on the backend.
- Parameters
-
[in] | recording | The class PVRRecording. |
[in] | lastplayedposition | The last watched position in seconds |
- Returns
- PVR_ERROR_NO_ERROR if the position has been stored successfully.
◆ SetRecordingLifetime()
Set the lifetime of a recording on the backend.
- Parameters
-
[in] | recording | The class PVRRecording to change the lifetime for. recording.iLifetime contains the new lieftime value. |
- Returns
- PVR_ERROR_NO_ERROR if the recording's lifetime has been set successfully.
◆ SetRecordingPlayCount()
Set the play count of a recording on the backend.
- Parameters
-
- Returns
- PVR_ERROR_NO_ERROR if the recording's play count has been set successfully.
◆ TriggerRecordingUpdate()
void kodi::addon::CInstancePVRClient::TriggerRecordingUpdate |
( |
| ) |
|
|
inline |
Callback to Kodi Function
Request Kodi to update it's list of recordings.
◆ UndeleteRecording()
Undelete a recording on the backend.
- Parameters
-
- Returns
- PVR_ERROR_NO_ERROR if the recording has been undeleted successfully.