Trait valence::nbt::binary::ToModifiedUtf8

pub trait ToModifiedUtf8 {
    // Required methods
    fn modified_uf8_len(&self) -> usize;
    fn to_modified_utf8<W>(
        &self,
        encoded_len: usize,
        writer: W,
    ) -> Result<(), Error>
       where W: Write;
}
Expand description

A string type which can be encoded into Java’s modified UTF-8.

Required Methods§

fn modified_uf8_len(&self) -> usize

fn to_modified_utf8<W>( &self, encoded_len: usize, writer: W, ) -> Result<(), Error>
where W: Write,

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

§

impl ToModifiedUtf8 for Cow<'_, str>

§

fn modified_uf8_len(&self) -> usize

§

fn to_modified_utf8<W>( &self, encoded_len: usize, writer: W, ) -> Result<(), Error>
where W: Write,

§

impl ToModifiedUtf8 for Cow<'_, JavaStr>

§

fn modified_uf8_len(&self) -> usize

§

fn to_modified_utf8<W>( &self, encoded_len: usize, writer: W, ) -> Result<(), Error>
where W: Write,

§

impl ToModifiedUtf8 for str

§

fn modified_uf8_len(&self) -> usize

§

fn to_modified_utf8<W>( &self, encoded_len: usize, writer: W, ) -> Result<(), Error>
where W: Write,

§

impl ToModifiedUtf8 for String

§

fn modified_uf8_len(&self) -> usize

§

fn to_modified_utf8<W>( &self, encoded_len: usize, writer: W, ) -> Result<(), Error>
where W: Write,

§

impl ToModifiedUtf8 for JavaStr

§

fn modified_uf8_len(&self) -> usize

§

fn to_modified_utf8<W>( &self, _encoded_len: usize, writer: W, ) -> Result<(), Error>
where W: Write,

§

impl ToModifiedUtf8 for JavaString

§

fn modified_uf8_len(&self) -> usize

§

fn to_modified_utf8<W>( &self, encoded_len: usize, writer: W, ) -> Result<(), Error>
where W: Write,

Implementors§