Struct neovim::Metadata
[−]
[src]
pub struct Metadata { pub buffer_id: i64, pub window_id: i64, pub tabpage_id: i64, }
Type identifiers for certain types, determined at runtime.
Fields
buffer_id: i64
window_id: i64
tabpage_id: i64
Methods
impl Metadata
[src]
fn new(metadata: Value) -> Result<Metadata, GetMetadataError>
Attempt to read metadata information from the provided value.
This method expects the value to represent this type of data structure:
{
"types": {
"Buffer": { "id": <int> },
"Window": { "id": <int> },
"Tabpage": { "id": <int> }
}
}
It then pulls out the id values and stores them in the returned Metadata
struct
so that buffer, window, and tabpage values received from Neovim can be parsed
appropriately.