pub struct Datetime { /* private fields */ }
Expand description
A Datetime type implemented using the builtin tarantool api. Note that
this api is not available in all versions of tarantool.
Use tarantool::ffi::has_datetime
to check if it is supported in your
case.
If has_datetime
return false
, using functions from this module
may result in a panic.
Implementations§
source§impl Datetime
impl Datetime
pub fn from_inner(inner: OffsetDateTime) -> Self
pub fn into_inner(self) -> OffsetDateTime
Trait Implementations§
source§impl<'de> Deserialize<'de> for Datetime
impl<'de> Deserialize<'de> for Datetime
source§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl From<Datetime> for OffsetDateTime
impl From<Datetime> for OffsetDateTime
source§impl From<OffsetDateTime> for Datetime
impl From<OffsetDateTime> for Datetime
source§fn from(inner: OffsetDateTime) -> Self
fn from(inner: OffsetDateTime) -> Self
Converts to this type from the input type.
source§impl<L> LuaRead<L> for Datetimewhere
L: AsLua,
impl<L> LuaRead<L> for Datetimewhere
L: AsLua,
source§fn lua_read_at_position(lua: L, index: NonZeroI32) -> ReadResult<Self, L>
fn lua_read_at_position(lua: L, index: NonZeroI32) -> ReadResult<Self, L>
Reads the data from Lua at a given position.
fn n_values_expected() -> i32
fn lua_read_at_maybe_zero_position(
lua: L,
index: i32
) -> Result<Self, (L, WrongType)>where
L: AsLua,
source§impl Ord for Datetime
impl Ord for Datetime
source§impl PartialEq for Datetime
impl PartialEq for Datetime
source§impl PartialOrd for Datetime
impl PartialOrd for Datetime
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresource§impl<L: AsLua> Push<L> for Datetime
impl<L: AsLua> Push<L> for Datetime
source§impl<L: AsLua> PushInto<L> for Datetime
impl<L: AsLua> PushInto<L> for Datetime
impl Copy for Datetime
impl Eq for Datetime
impl<L: AsLua> PushOne<L> for Datetime
impl<L: AsLua> PushOneInto<L> for Datetime
impl StructuralEq for Datetime
impl StructuralPartialEq for Datetime
Auto Trait Implementations§
impl RefUnwindSafe for Datetime
impl Send for Datetime
impl Sync for Datetime
impl Unpin for Datetime
impl UnwindSafe for Datetime
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more