Struct PsqlClientRef

Source
pub struct PsqlClientRef<'a> { /* private fields */ }

Trait Implementations§

Source§

impl<'a> Clone for PsqlClientRef<'a>

Source§

fn clone(&self) -> PsqlClientRef<'a>

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl<'a> Debug for PsqlClientRef<'a>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl From<&PsqlClientRef<'_>> for PsqlClient

Source§

fn from(r: &PsqlClientRef<'_>) -> Self

Converts to this type from the input type.
Source§

impl From<PsqlClientRef<'_>> for PsqlClient

Source§

fn from(value: PsqlClientRef<'_>) -> Self

Converts to this type from the input type.
Source§

impl<'a> From<PsqlClientRef<'a>> for &'a [u8]

Source§

fn from(value: PsqlClientRef<'a>) -> Self

Converts to this type from the input type.
Source§

impl<'a> FromBytesRef<'a> for PsqlClientRef<'a>

Source§

fn from_bytes_unchecked(_bytes: &'a [u8]) -> Self

Converts a slice of bytes into a LayerRef type. Read more
Source§

fn from_bytes(bytes: &'a [u8]) -> Result<Self, ValidationError>

Converts a slice of bytes into a LayerRef type, returning an error if the bytes would not form a valid layer.
Source§

impl<'a> IndexLayerRef<'a> for PsqlClientRef<'a>

Source§

fn get_layer<T: LayerRef<'a> + FromBytesRef<'a>>(&'a self) -> Option<T>

Retrieves a reference to the first sublayer of type T, if such a sublayer exists. Read more
Source§

fn get_nth_layer<T: LayerRef<'a> + FromBytesRef<'a> + BaseLayerMetadata>( &'a self, n: usize, ) -> Option<T>

Retrieves a reference to the nth sublayer of type T, if such a sublayer exists. Read more
Source§

fn index_layer<T: LayerRef<'a> + FromBytesRef<'a> + BaseLayerMetadata>( &'a self, ) -> T

Retrieves a reference to the first sublayer of type T. Read more
Source§

fn index_nth_layer<T: LayerRef<'a> + FromBytesRef<'a> + BaseLayerMetadata>( &'a self, n: usize, ) -> T

Retrieves a reference to the nth sublayer of type T. Read more
Source§

impl LayerIdentifier for PsqlClientRef<'_>

Source§

fn layer_id() -> LayerId

A unique identifier for the layer type. Read more
Source§

impl LayerLength for PsqlClientRef<'_>

Source§

fn len(&self) -> usize

The length (in bytes) of the layer. Read more
Source§

impl<'a> LayerObjectMetadata for PsqlClientRef<'a>

Source§

fn layer_metadata(&self) -> &dyn LayerMetadata

Static metadata associated with the given layer. This method is normally only used internally or when defining a custom Layer type.
Source§

impl<'a> LayerObjectName for PsqlClientRef<'a>

Source§

fn layer_name(&self) -> &'static str

The name of the layer, usually (though not guaranteed to be) the same as the name of the struct. Read more
Source§

impl<'a> LayerOffset for PsqlClientRef<'a>

Source§

fn payload_byte_index_default( _bytes: &[u8], _layer_type: LayerId, ) -> Option<usize>

Gets the index of the first byte of the layer specified by layer_type, if such a layer exists. This will not check the current layer against layer_type.
Source§

impl<'a> ToBoxedLayer for PsqlClientRef<'a>

Available on crate feature alloc only.
Source§

fn to_boxed_layer(&self) -> Box<dyn LayerObject>

Clone the given instance in a Box and return it as a dyn Layer type.
Source§

impl ToLayer for PsqlClientRef<'_>

Available on crate feature alloc only.
Source§

type Owned = PsqlClient

Source§

fn to_layer(&self) -> Self::Owned

Creates a new Layer out of the given layer instance.
Source§

impl<'a> Validate for PsqlClientRef<'a>

Source§

fn validate(bytes: &[u8]) -> Result<(), ValidationError>

Checks that bytes represents a valid serialization of the layer type. Read more
Source§

impl<'a> Copy for PsqlClientRef<'a>

Source§

impl<'a> LayerRef<'a> for PsqlClientRef<'a>

Source§

impl<'a> StatelessLayer for PsqlClientRef<'a>

Auto Trait Implementations§

§

impl<'a> Freeze for PsqlClientRef<'a>

§

impl<'a> RefUnwindSafe for PsqlClientRef<'a>

§

impl<'a> Send for PsqlClientRef<'a>

§

impl<'a> Sync for PsqlClientRef<'a>

§

impl<'a> Unpin for PsqlClientRef<'a>

§

impl<'a> UnwindSafe for PsqlClientRef<'a>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> AsAny for T
where T: Any,

Source§

fn as_any(&self) -> &(dyn Any + 'static)

Return a dyn Any reference to self.
Source§

fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)

Return a mutable dyn Any reference to self.
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.