Skip to content

RDKDEV-1793: Add Firebolt-cpp-client Documentation - #120

Open
gourivarma3 wants to merge 1 commit into
rdkcentral:developfrom
gourivarma3:feature/RDKDEV-1793
Open

gourivarma3 wants to merge 1 commit into
rdkcentral:developfrom
gourivarma3:feature/RDKDEV-1793

Conversation

@gourivarma3

Copy link
Copy Markdown

RDKDEV-1793
Reason for Change: To add Component Documentation for firebolt-cpp-client.
Fix: Added the README documentation
Test Procedure: None

I have read the CLA Document and I hereby sign the CLA
Signed-off-by: gourivarma3 gouri_varma@comcast.com

Copilot AI balanced review requested due to automatic review settings October 9, 2026 10:02

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

Several API inventories, event names, lifecycle details, and build-option descriptions do not match the implementation.

6 open findings
What changed in this PR

Adds component documentation describing the client architecture, APIs, lifecycle, interactions, configuration, and build options.

Changes:

  • Documents architecture and runtime flows with Mermaid diagrams.
  • Catalogs modules, events, dependencies, and configuration.
  • Summarizes build-time CMake options.
File Description
docs/​README.md Adds comprehensive component documentation.

🧠 Review effort: Balanced


💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread docs/README.md
Comment on lines +207 to +209
## Internal Modules

| Module / Class | Description | Key Files |
Comment thread docs/README.md
| `AccessibilityImpl` | Implements `IAccessibility`. Exposes audio description, closed-caption settings, high-contrast UI, and voice-guidance settings, with subscription support for each property. | `src/accessibility_impl.cpp`, `src/accessibility_impl.h` |
| `ActionsImpl` | Implements `IActions`. Provides `intent()` to retrieve the current app intent, `subscribeOnIntent()` for live intent change notifications, and `start()` to dispatch a new intent to a handler app. Auto-generated from the OpenRPC spec. | `src/actions_impl.cpp`, `src/actions_impl.h` |
| `AdvertisingImpl` | Implements `IAdvertising`. Provides `advertisingId()` returning an `Ifa` struct containing the advertising identifier, type, and limit-ad-tracking flag. | `src/advertising_impl.cpp`, `src/advertising_impl.h` |
| `DeviceImpl` | Implements `IDevice`. Provides chipset ID, device class (STB/OTT/TV), HDR format capabilities, uptime, UID, active-state time, and Dolby Atmos experience availability, with subscriptions for HDR and Dolby Atmos changes. | `src/device_impl.cpp`, `src/device_impl.h` |
Comment thread docs/README.md
| `PresentationImpl` | Implements `IPresentation`. Queries whether the application is currently focused (receiving key presses) and subscribes to focus change events. | `src/presentation_impl.cpp`, `src/presentation_impl.h` |
| `StatsImpl` | Implements `IStats`. Returns container memory statistics including user memory and GPU memory usage and limits via `memoryUsage()`. | `src/stats_impl.cpp`, `src/stats_impl.h` |
| `TextToSpeechImpl` | Implements `ITextToSpeech`. Provides TTS control: `listVoices()`, `speak()`, `pause()`, `resume()`, `cancel()`, `getSpeechState()`, and event subscriptions for speech lifecycle (willSpeak, speechStart, speechPause, speechResume, speechComplete, speechInterrupted, networkError, playbackError). | `src/texttospeech_impl.cpp`, `src/texttospeech_impl.h` |
| JSON type adapters | Per-domain structs under `json_types/` that bridge `nlohmann::json` deserialization to typed C++ domain structs. Each domain has a corresponding header (e.g., `json_types/device.h`, `json_types/lifecycle.h`). | `src/json_types/*.h` |
Comment thread docs/README.md
Comment on lines +261 to +268
| TTS will speak | `TextToSpeech.onWillspeak` | TTS engine is about to begin synthesizing speech | `ITextToSpeech` |
| TTS speech start | `TextToSpeech.onSpeechstart` | TTS audio playback starts | `ITextToSpeech` |
| TTS speech pause | `TextToSpeech.onSpeechpause` | TTS audio playback is paused | `ITextToSpeech` |
| TTS speech resume | `TextToSpeech.onSpeechresume` | TTS audio playback resumes | `ITextToSpeech` |
| TTS speech complete | `TextToSpeech.onSpeechcomplete` | TTS utterance finishes successfully | `ITextToSpeech` |
| TTS speech interrupted | `TextToSpeech.onSpeechinterrupted` | TTS utterance is interrupted | `ITextToSpeech` |
| TTS network error | `TextToSpeech.onNetworkerror` | TTS encounters a network error during synthesis | `ITextToSpeech` |
| TTS playback error | `TextToSpeech.onPlaybackerror` | TTS encounters a playback error during output | `ITextToSpeech` |
Comment thread docs/README.md
Comment on lines +309 to +310
- **State / Lifecycle Management**: The `FireboltAccessorImpl` destructor releases all active subscriptions before delegating disconnect to the transport.
- Connection management: `src/firebolt.cpp`
Comment thread docs/README.md

- **JSON Serialization Strategy**: Request parameters are serialized per domain in `*_impl.cpp` files. Optional parameters are included only when their `std::optional` value is present. Response deserialization relies on templated JSON adapter structs in `src/json_types/`.

- **Error Handling Strategy**: All API methods return a `Result<T>` type. Callers check the result for success or error before accessing the value.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants