pub trait PhantomDataExt {
// Required methods
fn type_name(&self) -> &'static str;
fn argument_sql(&self) -> Result<SqlMapping, ArgumentError>;
fn return_sql(&self) -> Result<Returns, ReturnsError>;
fn variadic(&self) -> bool;
fn optional(&self) -> bool;
fn entity(&self) -> FunctionMetadataTypeEntity;
}Expand description
An extension trait for PhantomData offering SQL generation related info
Since we don’t actually want to construct values during SQL generation, we use a PhantomData.
Required Methods§
fn type_name(&self) -> &'static str
fn argument_sql(&self) -> Result<SqlMapping, ArgumentError>
fn return_sql(&self) -> Result<Returns, ReturnsError>
fn variadic(&self) -> bool
fn optional(&self) -> bool
fn entity(&self) -> FunctionMetadataTypeEntity
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".