Struct PointArc
pub struct PointArc(/* private fields */);
Expand description
Arc around the byte repr Point
Send + Sync + cheap Clone, super::XHeader is immutable
Implementations§
Methods from Deref<Target = PFieldsThinPtr>§
pub fn pf_header(&self) -> &PFieldsHeader
pub fn as_sized(&self) -> &PFieldsPtr ⓘ
pub fn internal_consitent_length(&self) -> Result<(), Error>
pub fn internal_consitent_length(&self) -> Result<(), Error>
Check the header length fields and return the point size. This is the length without the hash.
pub fn check_signature(&self) -> Result<(), Error>
pub fn pfields_bytes(&self) -> &[u8] ⓘ
pub fn pfields_bytes(&self) -> &[u8] ⓘ
include padding
Trait Implementations§
§impl<'de> Deserialize<'de> for PointArc
impl<'de> Deserialize<'de> for PointArc
§fn deserialize<D>(
deserializer: D,
) -> Result<PointArc, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
fn deserialize<D>(
deserializer: D,
) -> Result<PointArc, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
§impl<'o> From<PointParts<'o>> for PointArc
impl<'o> From<PointParts<'o>> for PointArc
§fn from(value: PointParts<'o>) -> PointArc ⓘ
fn from(value: PointParts<'o>) -> PointArc ⓘ
Converts to this type from the input type.
§impl Point for PointArc
impl Point for PointArc
fn hash_ref(&self) -> &B64<[u8; 32]>
fn xheader_ref(&self) -> &XHeader
fn as_arc(&self) -> PointArc ⓘ
fn byte_segments(&self) -> ByteSegments<'_>
fn as_fields(&self) -> &dyn PFields
§fn recv(&self) -> Option<U64>
fn recv(&self) -> Option<U64>
recv is a special field.
It depends on the context. Reading directly from the database it should return the stamp at which it was inserted.
NOTE: Do not rely on this value being unique - in the db or otherwise.
fn as_box(&self) -> PointBox ⓘ
§impl Serialize for PointArc
impl Serialize for PointArc
§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
Auto Trait Implementations§
impl Freeze for PointArc
impl RefUnwindSafe for PointArc
impl Send for PointArc
impl Sync for PointArc
impl Unpin for PointArc
impl UnwindSafe for PointArc
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,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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 more§impl<T> PFields for Twhere
T: PointExt,
impl<T> PFields for Twhere
T: PointExt,
fn data(&self) -> &[u8] ⓘ
fn tail(&self) -> Option<Tail<'_>>
§fn padding(&self) -> &[u8] ⓘ
fn padding(&self) -> &[u8] ⓘ
Points are padded with upto 7 \xFF bytes and are u64 aligned - this is accessible here for completeness sake.
§fn linkpoint_header(&self) -> Option<&LinkPointHeader>
fn linkpoint_header(&self) -> Option<&LinkPointHeader>
Return a LinkPFieldsHeader, works for both key and link points.
§fn pfields_segments(&self) -> ByteSegments<'_>
fn pfields_segments(&self) -> ByteSegments<'_>
A utility function to translate this format into bytes for hashing & io