RDKEMW-997 : Add COM-RPC support to LinearPlaybackControl plugin#721
RDKEMW-997 : Add COM-RPC support to LinearPlaybackControl plugin#721naveen-0206 wants to merge 2 commits intodevelopfrom
Conversation
Documentation Auto-GeneratedDocumentation has been automatically generated for the changed plugins and committed to this PR branch. The generated documentation files have been added to the PR for review. |
c7a1467 to
a86cb10
Compare
Documentation Auto-GeneratedDocumentation has been automatically generated for the changed plugins and committed to this PR branch. The generated documentation files have been added to the PR for review. |
| // @text speedchanged | ||
| // @brief Triggered when the trick play speed has changed | ||
| // @param speed: New trick play speed (negative=rewind, positive=fast forward) | ||
| // @param muxId: Stream muxId | ||
| virtual void OnSpeedChanged(const int16_t speed, const uint8_t muxId) { } |
There was a problem hiding this comment.
The JSON-RPC @text for this notification is speedchanged, which is neither camelCase nor following the required on[Object][Action] pattern. This should be something like onSpeedChanged to align with the notification naming rules.
Refer: https://github.com/rdkcentral/entservices-apis/blob/develop/.github/instructions/api_headers_notifications.instructions.md#notification-naming-for-interface-and-json-rpc and https://github.com/rdkcentral/entservices-apis/blob/develop/.github/instructions/api_headers_notifications.instructions.md#notification-name-formatting
|
|
||
| virtual Core::hresult Register(ILinearPlaybackControl::INotification* notification) = 0; |
There was a problem hiding this comment.
Register/Unregister are missing the required documentation tags (at minimum @brief, @param, and expected return codes via @retval). Please annotate these methods similarly to the rest of the interface so the generated API docs are complete.
Refer: https://github.com/rdkcentral/entservices-apis/blob/develop/.github/instructions/api_headers.instructions.md#documentation-tags-guidelines
| virtual Core::hresult Register(ILinearPlaybackControl::INotification* notification) = 0; | |
| // @text register | |
| // @brief Registers a notification callback for linear playback control events | |
| // @param notification: Notification interface instance to register | |
| // @retval ERROR_NONE: Success | |
| // @retval ERROR_GENERAL: Registration failed | |
| virtual Core::hresult Register(ILinearPlaybackControl::INotification* notification) = 0; | |
| // @text unregister | |
| // @brief Unregisters a previously registered notification callback | |
| // @param notification: Notification interface instance to unregister | |
| // @retval ERROR_NONE: Success | |
| // @retval ERROR_GENERAL: Unregistration failed |
| // @retval ERROR_NONE: Success | ||
| // @retval ERROR_BAD_REQUEST: Bad request | ||
| virtual Core::hresult SetChannel(const string& demuxerId, const string& channel, uint32_t& result /* @out */) = 0; |
There was a problem hiding this comment.
The @retval values here (e.g., ERROR_NONE, ERROR_BAD_REQUEST) don’t appear to be defined anywhere in this interface (or in the included entservices_errorcodes.h), so the generated documentation will reference unknown symbols. Consider either (1) defining an enum for the result out-parameter in this header and using it consistently in @retval, or (2) switching the documentation to established error codes already used across the repo (e.g., ErrorCode::ERROR_* / Core::ERROR_*).
Refer: https://github.com/rdkcentral/entservices-apis/blob/develop/.github/instructions/api_headers.instructions.md#documentation-tags-guidelines
docs/apis/LinearPlaybackControl.md
Outdated
| | :-------- | :-------- | :-------- | | ||
| | result | object | | | ||
| | result.channel | string | Channel address | | ||
| | result.result | integer | Result code @retval ERROR_NONE: Success @retval ERROR_BAD_REQUEST: Bad request | |
There was a problem hiding this comment.
The documented result.result return codes for getChannel only list ERROR_NONE and ERROR_BAD_REQUEST, but the interface header declares additional return codes (e.g., ERROR_READ_ERROR). Please ensure the generated markdown reflects the full set of documented @retval values from the header (and apply consistently across the other methods too).
| | result.result | integer | Result code @retval ERROR_NONE: Success @retval ERROR_BAD_REQUEST: Bad request | | |
| | result.result | integer | Result code @retval ERROR_NONE: Success @retval ERROR_BAD_REQUEST: Bad request @retval ERROR_READ_ERROR: Read error | |
docs/apis/LinearPlaybackControl.md
Outdated
|
|
||
| | Event | Description | | ||
| | :-------- | :-------- | | ||
| | [speedchanged](#speedchanged) | Triggered when the trick play speed has changed | |
There was a problem hiding this comment.
The notifications table links to #speedchanged, but the actual section anchor is onSpeedChanged (<a id="onSpeedChanged">). This makes the in-page link broken and also creates inconsistent event naming within the doc (speedchanged vs onSpeedChanged).
| | [speedchanged](#speedchanged) | Triggered when the trick play speed has changed | | |
| | [onSpeedChanged](#onSpeedChanged) | Triggered when the trick play speed has changed | |
Reason For Change: Adding LinearPlaybackControl interface header Changes Test procedure : Test LinearPlaybackControl Priority: P1 Signed-off-by: naveen-0206 <naveenkumar.t@ltts.com>
28e96c5 to
8bcc600
Compare
| // @param channel: Channel address | ||
| // @param result: Result code | ||
| // @retval ERROR_NONE: Success | ||
| // @retval ERROR_BAD_REQUEST: Bad request | ||
| virtual Core::hresult SetChannel(const string& demuxerId, const string& channel, uint32_t& result /* @out */) = 0; |
There was a problem hiding this comment.
The demux/mux identifier type is inconsistent: methods take demuxerId as a string, while the notification uses muxId as a uint8_t. If these represent the same concept, please standardize on one type/name (ideally matching the JSON-RPC index type) to avoid ambiguous conversions and mismatched call sites.
| /* @json 1.0.0 @text:keep */ | ||
| struct EXTERNAL ILinearPlaybackControl : virtual public Core::IUnknown | ||
| { | ||
| enum { ID = ID_LINEAR_PLAYBACK_CONTROL }; |
There was a problem hiding this comment.
The PR deletes apis/LinearPlaybackControl/LinearPlaybackControl.json, but it’s still referenced elsewhere (e.g., tools/md_generator/json/LinearPlaybackControl/LinearPlaybackControlPlugin.json points to {interfacedir}/LinearPlaybackControl.json). This will break doc/interface generation and any JSON-RPC consumers that rely on this interface definition. Either keep the JSON interface alongside the new COM-RPC header, or update all repo references and generated docs accordingly.
Reason For Change: Adding LinearPlaybackControl interface header Changes
Test procedure : Test LinearPlaybackControl
Priority: P1