[][src]Struct sfv::RefItemSerializer

pub struct RefItemSerializer<'a> {
    pub buffer: &'a mut String,
}

Serializes Item field value components incrementally.

use sfv::{RefBareItem, RefItemSerializer};

let mut serialized_item = String::new();
let serializer = RefItemSerializer::new(&mut serialized_item);
serializer
.bare_item(&RefBareItem::Integer(11))
.unwrap()
.parameter("foo", &RefBareItem::Boolean(true))
.unwrap();
assert_eq!(serialized_item, "11;foo");

Fields

buffer: &'a mut String

Implementations

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

pub fn new(buffer: &'a mut String) -> Self[src]

pub fn bare_item(
    self,
    bare_item: &RefBareItem
) -> Result<RefParameterSerializer<'a>, &'static str>
[src]

Trait Implementations

impl<'a> Debug for RefItemSerializer<'a>[src]

Auto Trait Implementations

impl<'a> RefUnwindSafe for RefItemSerializer<'a>

impl<'a> Send for RefItemSerializer<'a>

impl<'a> Sync for RefItemSerializer<'a>

impl<'a> Unpin for RefItemSerializer<'a>

impl<'a> !UnwindSafe for RefItemSerializer<'a>

Blanket Implementations

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

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

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

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.