Trait SceneMigration
pub trait SceneMigration: Send + Sync {
// Required methods
fn from_version(&self) -> u32;
fn to_version(&self) -> u32;
fn migrate(&self, payload: &[u8]) -> Result<Vec<u8>, MigrationError>;
}Expand description
One step of a scene-format migration. Receives the raw payload bytes emitted by the previous version’s strategy and returns the bytes the next version’s strategy expects.
Required Methods§
fn from_version(&self) -> u32
fn from_version(&self) -> u32
Source format version (matches SceneHeader.format_version).
fn to_version(&self) -> u32
fn to_version(&self) -> u32
Target format version produced by this migration.