Skip to main content

Int64

Struct Int64 

Source
pub struct Int64;
Expand description

Codec for the Int64 proto scalar type.

Trait Implementations§

Source§

impl ExtensionCodec for Int64

Source§

type Value = i64

The value type passed to ExtensionSet::set_extension.
Source§

type Output = Option<i64>

The return type of ExtensionSet::extension.
Source§

fn decode(number: u32, fields: &UnknownFields) -> Option<i64>

Decode this extension’s value from the extendee’s unknown fields.
Source§

fn try_encode( number: u32, value: i64, fields: &mut UnknownFields, ) -> Result<(), EncodeError>

Encode value into the extendee’s unknown fields. Read more
Source§

fn encode(number: u32, value: Self::Value, fields: &mut UnknownFields)

Panicking wrapper over try_encode. Read more
Source§

impl PackableCodec for Int64

Source§

fn encode_packed(v: &i64, buf: &mut Vec<u8>)

Write one value’s wire payload (without tag) into buf.
Source§

impl SingularCodec for Int64

Source§

type Value = i64

Source§

fn decode_one(data: &UnknownFieldData) -> Option<i64>

Decode one value from one unknown-field record’s data. Read more
Source§

fn decode_packed(bytes: &[u8], out: &mut Vec<i64>)

Decode all values from a packed LengthDelimited payload. Read more
Source§

fn try_encode_one(v: &i64) -> Result<UnknownFieldData, EncodeError>

Encode one value as a single unknown-field record. Read more
Source§

fn decode_one_ctx( data: &UnknownFieldData, _ctx: DecodeContext<'_>, ) -> Option<Self::Value>

Decode one value under a decode context shared with the other records of the same field. Read more
Source§

fn encode_one(value: &Self::Value) -> UnknownFieldData

Panicking wrapper over try_encode_one. Read more

Auto Trait Implementations§

§

impl Forget for Int64

§

impl Freeze for Int64

§

impl Move for Int64

§

impl RefUnwindSafe for Int64

§

impl Send for Int64

§

impl Sync for Int64

§

impl Unpin for Int64

§

impl UnsafeUnpin for Int64

§

impl UnwindSafe for Int64

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> 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> 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, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

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

fn try_from(value: U) -> Result<T, !>

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.