Classes | |
| struct | RestoreDiagnosticPolicy |
| struct | RestoreDiagnostics |
Typedefs | |
| using | EnvelopeMigrationFn |
Enumerations | |
| enum class | RestoreBlobFormat : uint8_t { unknown , legacy_state_store , envelope } |
| enum class | RestoreDiagnosticStatus : uint8_t { ok , empty_blob , unknown_format , truncated_envelope , unsupported_envelope_version , envelope_migration_unavailable , payload_size_mismatch , crc_mismatch , empty_store_payload , total_size_budget_exceeded , store_size_budget_exceeded , plugin_size_budget_exceeded } |
Functions | |
| uint32_t | current_envelope_version () |
| const char * | restore_diagnostic_status_name (RestoreDiagnosticStatus status) noexcept |
| RestoreDiagnostics | inspect_restore_blob (std::span< const uint8_t > bytes, const RestoreDiagnosticPolicy &policy={}) noexcept |
| Inspect a host-facing plugin state blob without mutating live plugin state. | |
| bool | register_envelope_migration (uint32_t from_version, uint32_t to_version, EnvelopeMigrationFn migration) |
| std::vector< uint8_t > | serialize (const state::StateStore &store, const Processor &processor) |
| Serialize the host-facing plugin state blob for a Processor. | |
| bool | deserialize (std::span< const uint8_t > bytes, state::StateStore &store, Processor &processor) |
| Restore a host-facing plugin state blob. | |
|
strong |
|
strong |
| uint32_t pulp::format::plugin_state_io::current_envelope_version | ( | ) |
| bool pulp::format::plugin_state_io::deserialize | ( | std::span< const uint8_t > | bytes, |
| state::StateStore & | store, | ||
| Processor & | processor ) |
Restore a host-facing plugin state blob.
Accepts both legacy raw StateStore blobs and the combined envelope emitted by serialize(). On failure, the live StateStore is rolled back to its previous state before returning false.
|
nodiscardnoexcept |
Inspect a host-facing plugin state blob without mutating live plugin state.
This performs structural validation, size-budget checks, and large-state / plugin-payload signaling so callers can decide whether restore and resource relink work should be dispatched asynchronously.
| bool pulp::format::plugin_state_io::register_envelope_migration | ( | uint32_t | from_version, |
| uint32_t | to_version, | ||
| EnvelopeMigrationFn | migration ) |
|
nodiscardnoexcept |
| std::vector< uint8_t > pulp::format::plugin_state_io::serialize | ( | const state::StateStore & | store, |
| const Processor & | processor ) |
Serialize the host-facing plugin state blob for a Processor.
StateStore remains the parameter-only inner payload. When the processor exposes a non-empty plugin-owned blob, this helper wraps both payloads in a versioned outer envelope. When the plugin-owned blob is empty, the legacy raw StateStore blob is returned unchanged.