Struct json::object::Object [] [src]

pub struct Object { /* fields omitted */ }

A binary tree implementation of a string -> JsonValue map. You normally don't have to interact with instances of Object, much more likely you will be using the JsonValue::Object variant, which wraps around this struct.

Methods

impl Object
[src]

Create a new, empty instance of Object. Empty Object performs no allocation until a value is inserted into it.

Create a new Object with memory preallocated for capacity number of entries.

Insert a new entry, or override an existing one. Note that key has to be a &str slice and not an owned String. The internals of Object will handle the heap allocation of the key if needed for better performance.

Attempts to remove the value behind key, if successful will return the JsonValue stored behind the key.

Wipe the Object clear. The capacity will remain untouched.

Trait Implementations

impl PartialEq<JsonValue> for Object
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

impl Debug for Object
[src]

Formats the value using the given formatter.

impl Clone for Object
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl PartialEq for Object
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.