pub struct Node {
pub name: String,
pub type: NodeSpec,
pub top_node: bool,
}
Fields§
§name: String
§type: NodeSpec
§top_node: bool
Implementations§
Source§impl Node
impl Node
pub fn create(name: &str, spec: NodeSpec) -> Node
pub fn set_name(&mut self, name: &str) -> &mut Self
pub fn set_top_node(&mut self) -> &mut Self
pub fn is_top_node(&self) -> bool
pub fn get_name(&self) -> &str
pub fn set_content(&mut self, content: &str) -> &mut Self
pub fn set_marks(&mut self, marks: String) -> &mut Self
pub fn set_attrs(&mut self, attrs: HashMap<String, AttributeSpec>) -> &mut Self
pub fn set_attr(&mut self, name: &str, default: Option<Value>) -> &mut Self
pub fn set_desc(&mut self, desc: &str) -> &mut Self
Trait Implementations§
impl Eq for Node
impl StructuralPartialEq for Node
Auto Trait Implementations§
impl Freeze for Node
impl RefUnwindSafe for Node
impl Send for Node
impl Sync for Node
impl Unpin for Node
impl UnwindSafe for Node
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more