Enum rusqlite::types::ValueRef [−][src]
Expand description
A non-owning dynamic type value. Typically the memory backing this value is owned by SQLite.
See Value
for an owning dynamic type value.
Variants
The value is a NULL
value.
Integer(i64)
The value is a signed integer.
Tuple Fields of Integer
0: i64
Real(f64)
The value is a floating point number.
Tuple Fields of Real
0: f64
The value is a text string.
The value is a blob of data
Implementations
If self
is case Integer
, returns the integral value. Otherwise,
returns [Err(Error::InvalidColumnType)
](crate::Error::
InvalidColumnType).
If self
is case Null
returns None.
If self
is case Integer
, returns the integral value.
Otherwise returns [Err(Error::InvalidColumnType)
](crate::Error::
InvalidColumnType).
If self
is case Real
, returns the floating point value. Otherwise,
returns [Err(Error::InvalidColumnType)
](crate::Error::
InvalidColumnType).
If self
is case Null
returns None.
If self
is case Real
, returns the floating point value.
Otherwise returns [Err(Error::InvalidColumnType)
](crate::Error::
InvalidColumnType).
If self
is case Text
, returns the string value. Otherwise, returns
Err(Error::InvalidColumnType)
.
If self
is case Null
returns None.
If self
is case Text
, returns the string value.
Otherwise returns [Err(Error::InvalidColumnType)
](crate::Error::
InvalidColumnType).
If self
is case Blob
, returns the byte slice. Otherwise, returns
Err(Error::InvalidColumnType)
.
If self
is case Null
returns None.
If self
is case Blob
, returns the byte slice.
Otherwise returns [Err(Error::InvalidColumnType)
](crate::Error::
InvalidColumnType).
Returns the byte slice that makes up this ValueRef if it’s either
ValueRef::Blob
or ValueRef::Text
.
If self
is case Null
returns None.
If self
is ValueRef::Blob
or ValueRef::Text
returns the byte
slice that makes up this value
Trait Implementations
Auto Trait Implementations
impl<'a> RefUnwindSafe for ValueRef<'a>
impl<'a> UnwindSafe for ValueRef<'a>
Blanket Implementations
Mutably borrows from an owned value. Read more