Skip to main content

DataFramePayloadFields

Trait DataFramePayloadFields 

Source
#[doc(hidden)]
pub trait DataFramePayloadFields { const FIELDS: &'static [&'static str]; const TAG: &'static str; }
Expand description

Reflection trait for #[derive(DataFrameRow)] types, used for compile-time collision detection in outer DataFrameRow enums.

Automatically emitted by the DataFrameRow derive macro alongside DataFrameRow. The outer enum’s codegen generates a const _: () assertion that calls assert_no_payload_field_collision using these associated constants, producing a clear compile error when an inner payload field name (after outer prefix expansion) would produce the same R column as the outer discriminant column.

§Constants

  • FIELDS: the resolved column names (after #[dataframe(rename = "...")]) that this type contributes directly. For structs: each column name. For enums: every payload field name across all variants (deduplicated).
  • TAG: the value of #[dataframe(tag = "...")] on this type, or "" if absent. The outer macro uses this as the discriminant suffix for inner-enum nested fields.

You should not implement this trait manually.

Required Associated Constants§

Source

const FIELDS: &'static [&'static str]

Resolved column names contributed by this type (post-rename, pre-prefix).

Source

const TAG: &'static str

Value of #[dataframe(tag = "...")] on this type, or "" if absent.

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§