pub struct IdentityId(/* private fields */);Expand description
Unique identifier for an identity within a corpus.
Identities are Level 3: cross-document entities with optional KB links. An identity may span multiple documents and link to knowledge bases.
Implementations§
Source§impl IdentityId
impl IdentityId
Sourcepub const ZERO: IdentityId
pub const ZERO: IdentityId
Zero ID constant.
Sourcepub const fn new(id: u64) -> IdentityId
pub const fn new(id: u64) -> IdentityId
Create a new ID.
Sourcepub const fn next(self) -> IdentityId
pub const fn next(self) -> IdentityId
Increment the ID and return the new value.
Sourcepub fn next_mut(&mut self) -> IdentityId
pub fn next_mut(&mut self) -> IdentityId
Increment this ID in place and return the old value. Useful for generating sequential IDs.
Trait Implementations§
Source§impl Add<u64> for IdentityId
impl Add<u64> for IdentityId
Source§type Output = IdentityId
type Output = IdentityId
The resulting type after applying the
+ operator.Source§impl AddAssign<u64> for IdentityId
impl AddAssign<u64> for IdentityId
Source§fn add_assign(&mut self, rhs: u64)
fn add_assign(&mut self, rhs: u64)
Performs the
+= operation. Read moreSource§impl Clone for IdentityId
impl Clone for IdentityId
Source§fn clone(&self) -> IdentityId
fn clone(&self) -> IdentityId
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 IdentityId
impl Debug for IdentityId
Source§impl Default for IdentityId
impl Default for IdentityId
Source§fn default() -> IdentityId
fn default() -> IdentityId
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for IdentityId
impl<'de> Deserialize<'de> for IdentityId
Source§fn deserialize<D>(
deserializer: D,
) -> Result<IdentityId, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
fn deserialize<D>(
deserializer: D,
) -> Result<IdentityId, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Display for IdentityId
impl Display for IdentityId
Source§impl From<i32> for IdentityId
impl From<i32> for IdentityId
Source§fn from(id: i32) -> IdentityId
fn from(id: i32) -> IdentityId
Converts to this type from the input type.
Source§impl From<u64> for IdentityId
impl From<u64> for IdentityId
Source§fn from(id: u64) -> IdentityId
fn from(id: u64) -> IdentityId
Converts to this type from the input type.
Source§impl From<usize> for IdentityId
impl From<usize> for IdentityId
Source§fn from(id: usize) -> IdentityId
fn from(id: usize) -> IdentityId
Converts to this type from the input type.
Source§impl Hash for IdentityId
impl Hash for IdentityId
Source§impl Ord for IdentityId
impl Ord for IdentityId
Source§fn cmp(&self, other: &IdentityId) -> Ordering
fn cmp(&self, other: &IdentityId) -> 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 IdentityId
impl PartialEq for IdentityId
Source§impl PartialOrd for IdentityId
impl PartialOrd for IdentityId
Source§impl Serialize for IdentityId
impl Serialize for IdentityId
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 IdentityId
impl Eq for IdentityId
impl StructuralPartialEq for IdentityId
Auto Trait Implementations§
impl Freeze for IdentityId
impl RefUnwindSafe for IdentityId
impl Send for IdentityId
impl Sync for IdentityId
impl Unpin for IdentityId
impl UnsafeUnpin for IdentityId
impl UnwindSafe for IdentityId
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§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> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> ToCompactString for Twhere
T: Display,
impl<T> ToCompactString for Twhere
T: Display,
Source§fn try_to_compact_string(&self) -> Result<CompactString, ToCompactStringError>
fn try_to_compact_string(&self) -> Result<CompactString, ToCompactStringError>
Fallible version of
ToCompactString::to_compact_string() Read moreSource§fn to_compact_string(&self) -> CompactString
fn to_compact_string(&self) -> CompactString
Converts the given value to a
CompactString. Read moreSource§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.