[][src]Struct protobuf::stream::CodedInputStream

pub struct CodedInputStream<'a> { /* fields omitted */ }

Methods

impl<'a> CodedInputStream<'a>[src]

Important traits for CodedInputStream<'a>
pub fn new(read: &'a mut dyn Read) -> CodedInputStream<'a>[src]

Important traits for CodedInputStream<'a>
pub fn from_buffered_reader(
    buf_read: &'a mut dyn BufRead
) -> CodedInputStream<'a>
[src]

Important traits for CodedInputStream<'a>
pub fn from_bytes(bytes: &'a [u8]) -> CodedInputStream<'a>[src]

pub fn set_recursion_limit(&mut self, limit: u32)[src]

Set the recursion limit.

pub fn pos(&self) -> u64[src]

pub fn bytes_until_limit(&self) -> u64[src]

pub fn read(&mut self, buf: &mut [u8]) -> ProtobufResult<()>[src]

pub fn read_raw_byte(&mut self) -> ProtobufResult<u8>[src]

pub fn push_limit(&mut self, limit: u64) -> ProtobufResult<u64>[src]

pub fn pop_limit(&mut self, old_limit: u64)[src]

pub fn eof(&mut self) -> ProtobufResult<bool>[src]

pub fn check_eof(&mut self) -> ProtobufResult<()>[src]

pub fn read_raw_varint64(&mut self) -> ProtobufResult<u64>[src]

pub fn read_raw_varint32(&mut self) -> ProtobufResult<u32>[src]

pub fn read_raw_little_endian32(&mut self) -> ProtobufResult<u32>[src]

pub fn read_raw_little_endian64(&mut self) -> ProtobufResult<u64>[src]

pub fn read_tag(&mut self) -> ProtobufResult<Tag>[src]

pub fn read_tag_unpack(&mut self) -> ProtobufResult<(u32, WireType)>[src]

pub fn read_double(&mut self) -> ProtobufResult<f64>[src]

pub fn read_float(&mut self) -> ProtobufResult<f32>[src]

pub fn read_int64(&mut self) -> ProtobufResult<i64>[src]

pub fn read_int32(&mut self) -> ProtobufResult<i32>[src]

pub fn read_uint64(&mut self) -> ProtobufResult<u64>[src]

pub fn read_uint32(&mut self) -> ProtobufResult<u32>[src]

pub fn read_sint64(&mut self) -> ProtobufResult<i64>[src]

pub fn read_sint32(&mut self) -> ProtobufResult<i32>[src]

pub fn read_fixed64(&mut self) -> ProtobufResult<u64>[src]

pub fn read_fixed32(&mut self) -> ProtobufResult<u32>[src]

pub fn read_sfixed64(&mut self) -> ProtobufResult<i64>[src]

pub fn read_sfixed32(&mut self) -> ProtobufResult<i32>[src]

pub fn read_bool(&mut self) -> ProtobufResult<bool>[src]

pub fn read_enum<E: ProtobufEnum>(&mut self) -> ProtobufResult<E>[src]

pub fn read_repeated_packed_double_into(
    &mut self,
    target: &mut Vec<f64>
) -> ProtobufResult<()>
[src]

pub fn read_repeated_packed_float_into(
    &mut self,
    target: &mut Vec<f32>
) -> ProtobufResult<()>
[src]

pub fn read_repeated_packed_int64_into(
    &mut self,
    target: &mut Vec<i64>
) -> ProtobufResult<()>
[src]

pub fn read_repeated_packed_int32_into(
    &mut self,
    target: &mut Vec<i32>
) -> ProtobufResult<()>
[src]

pub fn read_repeated_packed_uint64_into(
    &mut self,
    target: &mut Vec<u64>
) -> ProtobufResult<()>
[src]

pub fn read_repeated_packed_uint32_into(
    &mut self,
    target: &mut Vec<u32>
) -> ProtobufResult<()>
[src]

pub fn read_repeated_packed_sint64_into(
    &mut self,
    target: &mut Vec<i64>
) -> ProtobufResult<()>
[src]

pub fn read_repeated_packed_sint32_into(
    &mut self,
    target: &mut Vec<i32>
) -> ProtobufResult<()>
[src]

pub fn read_repeated_packed_fixed64_into(
    &mut self,
    target: &mut Vec<u64>
) -> ProtobufResult<()>
[src]

pub fn read_repeated_packed_fixed32_into(
    &mut self,
    target: &mut Vec<u32>
) -> ProtobufResult<()>
[src]

pub fn read_repeated_packed_sfixed64_into(
    &mut self,
    target: &mut Vec<i64>
) -> ProtobufResult<()>
[src]

pub fn read_repeated_packed_sfixed32_into(
    &mut self,
    target: &mut Vec<i32>
) -> ProtobufResult<()>
[src]

pub fn read_repeated_packed_bool_into(
    &mut self,
    target: &mut Vec<bool>
) -> ProtobufResult<()>
[src]

pub fn read_repeated_packed_enum_into<E: ProtobufEnum>(
    &mut self,
    target: &mut Vec<E>
) -> ProtobufResult<()>
[src]

pub fn read_unknown(
    &mut self,
    wire_type: WireType
) -> ProtobufResult<UnknownValue>
[src]

pub fn skip_field(&mut self, wire_type: WireType) -> ProtobufResult<()>[src]

pub fn read_raw_bytes_into(
    &mut self,
    count: u32,
    target: &mut Vec<u8>
) -> ProtobufResult<()>
[src]

Read raw bytes into the supplied vector. The vector will be resized as needed and overwritten.

pub fn read_raw_bytes(&mut self, count: u32) -> ProtobufResult<Vec<u8>>[src]

Read exact number of bytes

pub fn skip_raw_bytes(&mut self, count: u32) -> ProtobufResult<()>[src]

pub fn read_bytes(&mut self) -> ProtobufResult<Vec<u8>>[src]

pub fn read_bytes_into(&mut self, target: &mut Vec<u8>) -> ProtobufResult<()>[src]

pub fn read_string(&mut self) -> ProtobufResult<String>[src]

pub fn read_string_into(&mut self, target: &mut String) -> ProtobufResult<()>[src]

pub fn merge_message<M: Message>(
    &mut self,
    message: &mut M
) -> ProtobufResult<()>
[src]

pub fn read_message<M: Message>(&mut self) -> ProtobufResult<M>[src]

Trait Implementations

impl<'a> Read for CodedInputStream<'a>[src]

fn read_vectored(&mut self, bufs: &mut [IoSliceMut]) -> Result<usize, Error>1.36.0[src]

Like read, except that it reads into a slice of buffers. Read more

unsafe fn initializer(&self) -> Initializer[src]

🔬 This is a nightly-only experimental API. (read_initializer)

Determines if this Reader can work with buffers of uninitialized memory. Read more

fn read_to_end(&mut self, buf: &mut Vec<u8>) -> Result<usize, Error>1.0.0[src]

Read all bytes until EOF in this source, placing them into buf. Read more

fn read_to_string(&mut self, buf: &mut String) -> Result<usize, Error>1.0.0[src]

Read all bytes until EOF in this source, appending them to buf. Read more

fn read_exact(&mut self, buf: &mut [u8]) -> Result<(), Error>1.6.0[src]

Read the exact number of bytes required to fill buf. Read more

fn by_ref(&mut self) -> &mut Self1.0.0[src]

Creates a "by reference" adaptor for this instance of Read. Read more

fn bytes(self) -> Bytes<Self>1.0.0[src]

Transforms this Read instance to an [Iterator] over its bytes. Read more

fn chain<R>(self, next: R) -> Chain<Self, R> where
    R: Read
1.0.0[src]

Creates an adaptor which will chain this stream with another. Read more

fn take(self, limit: u64) -> Take<Self>1.0.0[src]

Creates an adaptor which will read at most limit bytes from it. Read more

impl<'a> BufRead for CodedInputStream<'a>[src]

fn read_until(&mut self, byte: u8, buf: &mut Vec<u8>) -> Result<usize, Error>1.0.0[src]

Read all bytes into buf until the delimiter byte or EOF is reached. Read more

fn read_line(&mut self, buf: &mut String) -> Result<usize, Error>1.0.0[src]

Read all bytes until a newline (the 0xA byte) is reached, and append them to the provided buffer. Read more

fn split(self, byte: u8) -> Split<Self>1.0.0[src]

Returns an iterator over the contents of this reader split on the byte byte. Read more

fn lines(self) -> Lines<Self>1.0.0[src]

Returns an iterator over the lines of this reader. Read more

Auto Trait Implementations

impl<'a> !Send for CodedInputStream<'a>

impl<'a> !Sync for CodedInputStream<'a>

Blanket Implementations

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]