pub trait SpringValue: ToNnSqlValue + Sized {
Show 13 methods
// Provided methods
fn into_sql_value(self) -> SqlValue { ... }
fn try_from_i16(_: &i16) -> Result<Self> { ... }
fn try_from_i32(_: &i32) -> Result<Self> { ... }
fn try_from_i64(_: &i64) -> Result<Self> { ... }
fn try_from_u16(_: &u16) -> Result<Self> { ... }
fn try_from_u32(_: &u32) -> Result<Self> { ... }
fn try_from_u64(_: &u64) -> Result<Self> { ... }
fn try_from_f32(_: &f32) -> Result<Self> { ... }
fn try_from_string(_: &str) -> Result<Self> { ... }
fn try_from_blob(_: &[u8]) -> Result<Self> { ... }
fn try_from_bool(_: &bool) -> Result<Self> { ... }
fn try_from_timestamp(_: &SpringTimestamp) -> Result<Self> { ... }
fn try_from_duration(_: &SpringEventDuration) -> Result<Self> { ... }
}
Expand description
Rust values can be unpacked from NnSqlValue back into them.
Provided Methods§
Sourcefn into_sql_value(self) -> SqlValue
fn into_sql_value(self) -> SqlValue
Convert Rust type into strictly-matching SQL type.
Sourcefn try_from_i16(_: &i16) -> Result<Self>
fn try_from_i16(_: &i16) -> Result<Self>
§Failures
SpringError::Sql
when:- the type implementing SqlConvertible is not convertible from i16
Sourcefn try_from_i32(_: &i32) -> Result<Self>
fn try_from_i32(_: &i32) -> Result<Self>
§Failures
SpringError::Sql
when:- the type implementing SqlConvertible is not convertible from i32
Sourcefn try_from_i64(_: &i64) -> Result<Self>
fn try_from_i64(_: &i64) -> Result<Self>
§Failures
SpringError::Sql
when:- the type implementing SqlConvertible is not convertible from i64
Sourcefn try_from_u16(_: &u16) -> Result<Self>
fn try_from_u16(_: &u16) -> Result<Self>
§Failures
SpringError::Sql
when:- the type implementing SqlConvertible is not convertible from u16
Sourcefn try_from_u32(_: &u32) -> Result<Self>
fn try_from_u32(_: &u32) -> Result<Self>
§Failures
SpringError::Sql
when:- the type implementing SqlConvertible is not convertible from u32
Sourcefn try_from_u64(_: &u64) -> Result<Self>
fn try_from_u64(_: &u64) -> Result<Self>
§Failures
SpringError::Sql
when:- the type implementing SqlConvertible is not convertible from u64
Sourcefn try_from_f32(_: &f32) -> Result<Self>
fn try_from_f32(_: &f32) -> Result<Self>
§Failures
SpringError::Sql
when:- the type implementing SqlConvertible is not convertible from f32
Sourcefn try_from_string(_: &str) -> Result<Self>
fn try_from_string(_: &str) -> Result<Self>
§Failures
SpringError::Sql
when:- the type implementing SqlConvertible is not convertible from String
Sourcefn try_from_blob(_: &[u8]) -> Result<Self>
fn try_from_blob(_: &[u8]) -> Result<Self>
§Failures
SpringError::Sql
when:- the type implementing SqlConvertible is not convertible from Vec
- the type implementing SqlConvertible is not convertible from Vec
Sourcefn try_from_bool(_: &bool) -> Result<Self>
fn try_from_bool(_: &bool) -> Result<Self>
§Failures
SpringError::Sql
when:- the type implementing SqlConvertible is not convertible from bool
Sourcefn try_from_timestamp(_: &SpringTimestamp) -> Result<Self>
fn try_from_timestamp(_: &SpringTimestamp) -> Result<Self>
§Failures
SpringError::Sql
when:- the type implementing SqlConvertible is not convertible from Timestamp
Sourcefn try_from_duration(_: &SpringEventDuration) -> Result<Self>
fn try_from_duration(_: &SpringEventDuration) -> Result<Self>
§Failures
SpringError::Sql
when:- the type implementing SqlConvertible is not convertible from EventDuration
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.