Preview of the proposed up-rust native-frame-model branch (up-rust b6b99c6d, up-spec f0e9b17) — not released documentation. branch · write-up

Trait StablePayload

Source
pub unsafe trait StablePayload: Sized + 'static {
    const TYPE_NAME: &'static str;
    const VARIANT: StablePayloadVariant = StablePayloadVariant::FixedSize;

    // Provided methods
    fn stable_type_name() -> &'static str { ... }
    fn stable_type_detail() -> StableTypeDetail<'static> { ... }
}
Expand description

Stable payload identity used by StableContainerPayload<T>.

This phase uses the trait only to build and verify stable-container metadata. Future borrow/no-zero phases consume the same identity when proving that bytes may safely be viewed as T.

§Safety

Implementors must choose a stable cross-process type name and only implement the trait for types whose size/alignment and initialized byte representation are suitable for the stable-container contract used by the application.

Required Associated Constants§

Source

const TYPE_NAME: &'static str

Stable cross-process type name.

Provided Associated Constants§

Source

const VARIANT: StablePayloadVariant = StablePayloadVariant::FixedSize

Stable-container variant supported by this type.

Provided Methods§

Source

fn stable_type_name() -> &'static str

Returns the stable cross-process type name.

Source

fn stable_type_detail() -> StableTypeDetail<'static>

Returns the stable metadata detail for this type.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl StablePayload for Ars548DetectionV1

Source§

const TYPE_NAME: &'static str = "org.eclipse.uprotocol.bench.v1.Ars548DetectionV1"

Source§

impl StablePayload for BenchHeaderV1

Source§

const TYPE_NAME: &'static str = "org.eclipse.uprotocol.bench.v1.BenchHeaderV1"

Source§

impl StablePayload for CameraBayerRggb12pFrame8mpV1

Source§

const TYPE_NAME: &'static str = "org.eclipse.uprotocol.bench.v1.CameraBayerRggb12pFrame8mpV1"

Source§

impl StablePayload for CameraIntrinsicsV1

Source§

const TYPE_NAME: &'static str = "org.eclipse.uprotocol.bench.v1.CameraIntrinsicsV1"

Source§

impl StablePayload for CanClassicFrameV1

Source§

const TYPE_NAME: &'static str = "org.eclipse.uprotocol.bench.v1.CanClassicFrameV1"

Source§

impl StablePayload for CanFdFrameV1

Source§

const TYPE_NAME: &'static str = "org.eclipse.uprotocol.bench.v1.CanFdFrameV1"

Source§

impl StablePayload for LidarPointCloudHesaiAt128V1

Source§

const TYPE_NAME: &'static str = "org.eclipse.uprotocol.bench.v1.LidarPointCloudHesaiAt128V1"

Source§

impl StablePayload for LidarPointXyzircaedtV1

Source§

const TYPE_NAME: &'static str = "org.eclipse.uprotocol.bench.v1.LidarPointXyzircaedtV1"

Source§

impl StablePayload for Pose3dV1

Source§

const TYPE_NAME: &'static str = "org.eclipse.uprotocol.bench.v1.Pose3dV1"

Source§

impl StablePayload for QuaternionfV1

Source§

const TYPE_NAME: &'static str = "org.eclipse.uprotocol.bench.v1.QuaternionfV1"

Source§

impl StablePayload for RadarDetectionListArs548V1

Source§

const TYPE_NAME: &'static str = "org.eclipse.uprotocol.bench.v1.RadarDetectionListArs548V1"

Source§

impl StablePayload for RoiV1

Source§

const TYPE_NAME: &'static str = "org.eclipse.uprotocol.bench.v1.RoiV1"

Source§

impl StablePayload for SignalSampleV1

Source§

const TYPE_NAME: &'static str = "org.eclipse.uprotocol.bench.v1.SignalSampleV1"

Source§

impl StablePayload for SomeIpSignalBatchMtuV1

Source§

const TYPE_NAME: &'static str = "org.eclipse.uprotocol.bench.v1.SomeIpSignalBatchMtuV1"

Source§

impl StablePayload for StreamChunk4kV1

Source§

const TYPE_NAME: &'static str = "org.eclipse.uprotocol.bench.v1.StreamChunk4kV1"

Source§

impl StablePayload for StreamChunk64kV1

Source§

const TYPE_NAME: &'static str = "org.eclipse.uprotocol.bench.v1.StreamChunk64kV1"

Source§

impl StablePayload for StreamChunkHeaderV1

Source§

const TYPE_NAME: &'static str = "org.eclipse.uprotocol.bench.v1.StreamChunkHeaderV1"

Source§

impl StablePayload for Vector3fV1

Source§

const TYPE_NAME: &'static str = "org.eclipse.uprotocol.bench.v1.Vector3fV1"

Source§

impl StablePayload for StableTestBytes

Source§

const TYPE_NAME: &'static str = "uprotocol.test.StableTestBytes"