Struct tikv_util::config::TomlWriter[][src]

pub struct TomlWriter {
    dst: Vec<u8>,
    current_table: String,
}

TomlWriter use to update the config file and only cover the most commom toml format that used by tikv config file, toml format like: quoted keys, multi-line value, inline table, etc, are not supported, see https://github.com/toml-lang/toml for more detail.

Fields

dst: Vec<u8>current_table: String

Implementations

impl TomlWriter[src]

pub fn new() -> TomlWriter[src]

pub fn write_change(&mut self, src: String, change: HashMap<String, String>)[src]

fn write_current_table(&mut self, change: &mut HashMap<String, String>)[src]

fn write(&mut self, s: &[u8])[src]

fn new_line(&mut self)[src]

pub fn finish(self) -> Vec<u8>

Notable traits for Vec<u8, A>

impl<A> Write for Vec<u8, A> where
    A: Allocator
[src]

Auto Trait Implementations

impl RefUnwindSafe for TomlWriter

impl Send for TomlWriter

impl Sync for TomlWriter

impl Unpin for TomlWriter

impl UnwindSafe for TomlWriter

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> Instrument for T[src]

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

impl<T> Pointable for T[src]

type Init = T

The type for initializers.

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

type Output = T

Should always be Self

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

impl<T> SendSyncUnwindSafe for T where
    T: Send + Sync + UnwindSafe + ?Sized
[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<V, T> VZip<V> for T where
    V: MultiLane<T>, 
[src]