Struct cdragon_prop::JsonSerializer
source · pub struct JsonSerializer<'a, W: Write> { /* private fields */ }
Expand description
Serialize bin values to JSON
Implementations§
source§impl<'a, W: Write> JsonSerializer<'a, W>
impl<'a, W: Write> JsonSerializer<'a, W>
sourcepub fn new(writer: W, hmappers: &'a BinHashMappers) -> Self
pub fn new(writer: W, hmappers: &'a BinHashMappers) -> Self
Create a new serializer
Trait Implementations§
source§impl<'a, W: Write> BinSerializer for JsonSerializer<'a, W>
impl<'a, W: Write> BinSerializer for JsonSerializer<'a, W>
type EntriesSerializer = JsonEntriesSerializer<'a, W>
source§fn write_entries(self) -> Result<Self::EntriesSerializer>
fn write_entries(self) -> Result<Self::EntriesSerializer>
Return a serializer to write streamed entries
fn write_none(&mut self, _: &BinNone) -> Result<()>
fn write_bool(&mut self, v: &BinBool) -> Result<()>
fn write_s8(&mut self, v: &BinS8) -> Result<()>
fn write_u8(&mut self, v: &BinU8) -> Result<()>
fn write_s16(&mut self, v: &BinS16) -> Result<()>
fn write_u16(&mut self, v: &BinU16) -> Result<()>
fn write_s32(&mut self, v: &BinS32) -> Result<()>
fn write_u32(&mut self, v: &BinU32) -> Result<()>
fn write_s64(&mut self, v: &BinS64) -> Result<()>
fn write_u64(&mut self, v: &BinU64) -> Result<()>
fn write_float(&mut self, v: &BinFloat) -> Result<()>
fn write_vec2(&mut self, v: &BinVec2) -> Result<()>
fn write_vec3(&mut self, v: &BinVec3) -> Result<()>
fn write_vec4(&mut self, v: &BinVec4) -> Result<()>
fn write_matrix(&mut self, v: &BinMatrix) -> Result<()>
fn write_color(&mut self, v: &BinColor) -> Result<()>
fn write_string(&mut self, v: &BinString) -> Result<()>
fn write_hash(&mut self, v: &BinHash) -> Result<()>
fn write_path(&mut self, v: &BinPath) -> Result<()>
fn write_link(&mut self, v: &BinLink) -> Result<()>
fn write_flag(&mut self, v: &BinFlag) -> Result<()>
fn write_list(&mut self, v: &BinList) -> Result<()>
fn write_struct(&mut self, v: &BinStruct) -> Result<()>
fn write_embed(&mut self, v: &BinEmbed) -> Result<()>
fn write_option(&mut self, option: &BinOption) -> Result<()>
fn write_map(&mut self, map: &BinMap) -> Result<()>
Auto Trait Implementations§
impl<'a, W> RefUnwindSafe for JsonSerializer<'a, W>where
W: RefUnwindSafe,
impl<'a, W> Send for JsonSerializer<'a, W>where
W: Send,
impl<'a, W> Sync for JsonSerializer<'a, W>where
W: Sync,
impl<'a, W> Unpin for JsonSerializer<'a, W>where
W: Unpin,
impl<'a, W> UnwindSafe for JsonSerializer<'a, W>where
W: UnwindSafe,
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