Struct toml_edit::Array [−][src]
pub struct Array { /* fields omitted */ }
Type representing a TOML array,
payload of the Value::Array
variant's value
Methods
impl Array
[src]
impl Array
pub fn len(&self) -> usize
[src]
pub fn len(&self) -> usize
Returns the length of the underlying Vec.
To get the actual number of items use a.iter().count()
.
pub fn is_empty(&self) -> bool
[src]
pub fn is_empty(&self) -> bool
Return true iff self.len() == 0
.
pub fn iter(&self) -> Box<Iterator<Item = &'a Value> + 'a>
[src]
pub fn iter(&self) -> Box<Iterator<Item = &'a Value> + 'a>
Returns an iterator over all values.
pub fn push<V: Into<Value>>(&mut self, v: V) -> bool
[src]
pub fn push<V: Into<Value>>(&mut self, v: V) -> bool
Appends a new value.
pub fn get(&mut self, index: usize) -> Option<&Value>
[src]
pub fn get(&mut self, index: usize) -> Option<&Value>
Return an optional reference to the value at the given index.
pub fn remove(&mut self, index: usize) -> Value
[src]
pub fn remove(&mut self, index: usize) -> Value
Removes the value at the given index.
pub fn fmt(&mut self)
[src]
pub fn fmt(&mut self)
Auto formats the array.
Trait Implementations
impl Display for Array
[src]
impl Display for Array
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl From<Array> for Value
[src]
impl From<Array> for Value
impl Debug for Array
[src]
impl Debug for Array
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl Default for Array
[src]
impl Default for Array
impl Clone for Array
[src]
impl Clone for Array