Expand description
§neco-plist-ast
necosystems series structured access layer for plist values.
§Features
- Owned
PlistDocumentwrappingPlistValuefor cross-crate trait use - Borrowed
PlistNode<'a>carrying an optional field key parsere-export that turns&strintoPlistDocumentStructuredDocumentimpl exposing mapping fields as top-level nodesStructuredNodeimpl providingkind,identifier,attribute,children, andvalue
§Usage
use neco_ast::{StructuredDocument, StructuredNode};
let doc = neco_plist_ast::parse("name = neco\n").unwrap();
let node = doc.nodes().remove(0);
assert_eq!(node.kind(), "name");§API
| Item | Description |
|---|---|
parse(input: &str) -> Result<PlistDocument, ParseError> | Parses input via neco-plist and wraps the value |
PlistDocument | Owned wrapper around PlistValue |
PlistNode<'a> | Borrowed view with an optional field key |
PlistDocument::from_value / as_value | Constructs from or reads the inner PlistValue |
PlistNode::from_value / as_value | Constructs a root view or reads the inner PlistValue |
impl StructuredDocument for PlistDocument | nodes() yields mapping fields, or the root value |
impl StructuredNode for PlistNode<'_> | Implements kind, identifier, attribute, children, and value |
§License
MIT