pub struct PaymentCreatedIndex {
pub created_at: TimestampMs,
pub id: PaymentId,
}Expand description
A unique, ordered payment identifier: (created_at, payment_id).
Suitable as a key in BTreeMap<PaymentCreatedIndex, Payment> or for
cursor-based pagination. Serialized as "<created_at>-<id>", e.g.
"0002683862736062841-ln_3ddc...".
Fields§
§created_at: TimestampMs§id: PaymentIdImplementations§
Source§impl PaymentCreatedIndex
impl PaymentCreatedIndex
Sourcepub const MIN: PaymentCreatedIndex
pub const MIN: PaymentCreatedIndex
The index that is lexicographically <= all other indexes.
Sourcepub const MAX: PaymentCreatedIndex
pub const MAX: PaymentCreatedIndex
The index that is lexicographically >= all other indexes.
Trait Implementations§
Source§impl Clone for PaymentCreatedIndex
impl Clone for PaymentCreatedIndex
Source§fn clone(&self) -> PaymentCreatedIndex
fn clone(&self) -> PaymentCreatedIndex
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for PaymentCreatedIndex
impl Debug for PaymentCreatedIndex
Source§impl<'de> Deserialize<'de> for PaymentCreatedIndex
impl<'de> Deserialize<'de> for PaymentCreatedIndex
Source§fn deserialize<__D>(
deserializer: __D,
) -> Result<PaymentCreatedIndex, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
deserializer: __D,
) -> Result<PaymentCreatedIndex, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Display for PaymentCreatedIndex
<created_at>-<id>
impl Display for PaymentCreatedIndex
<created_at>-<id>
When serializing to string, pad the timestamp with leading zeroes (up to the
maximum number of digits in an i64) so that the lexicographic ordering
is equivalent to the non-serialized ordering.
Source§impl FromStr for PaymentCreatedIndex
<created_at>-<id>
impl FromStr for PaymentCreatedIndex
<created_at>-<id>
Source§impl Ord for PaymentCreatedIndex
impl Ord for PaymentCreatedIndex
Source§fn cmp(&self, other: &PaymentCreatedIndex) -> Ordering
fn cmp(&self, other: &PaymentCreatedIndex) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for PaymentCreatedIndex
impl PartialEq for PaymentCreatedIndex
Source§impl PartialOrd for PaymentCreatedIndex
impl PartialOrd for PaymentCreatedIndex
Source§impl Serialize for PaymentCreatedIndexwhere
PaymentCreatedIndex: Display,
impl Serialize for PaymentCreatedIndexwhere
PaymentCreatedIndex: Display,
Source§fn serialize<__S>(
&self,
serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl Copy for PaymentCreatedIndex
impl Eq for PaymentCreatedIndex
impl StructuralPartialEq for PaymentCreatedIndex
Auto Trait Implementations§
impl Freeze for PaymentCreatedIndex
impl RefUnwindSafe for PaymentCreatedIndex
impl Send for PaymentCreatedIndex
impl Sync for PaymentCreatedIndex
impl Unpin for PaymentCreatedIndex
impl UnsafeUnpin for PaymentCreatedIndex
impl UnwindSafe for PaymentCreatedIndex
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
Source§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string, but without panic on OOM.