[−][src]Struct elvis_shared::Node
Virtual UI Node
Fields
attrs: HashMap<String, String>
Node attributes
children: Vec<Rc<RefCell<Node>>>
Node children
tag: String
Node tag
pre: Option<Weak<RefCell<Node>>>
Node parent
Implementations
impl Node
[src]
pub fn drain(t: Rc<RefCell<Node>>)
[src]
Drain tree if not the root
pub fn idx(&mut self, path: &mut Vec<u8>)
[src]
The path of current node
pub fn locate(&self, path: Vec<usize>) -> Vec<usize>
[src]
Locate tree
pub fn new(
attrs: HashMap<String, String>,
children: Vec<Rc<RefCell<Node>>>,
pre: Option<Weak<RefCell<Node>>>,
tag: String
) -> Rc<RefCell<Node>>
[src]
attrs: HashMap<String, String>,
children: Vec<Rc<RefCell<Node>>>,
pre: Option<Weak<RefCell<Node>>>,
tag: String
) -> Rc<RefCell<Node>>
Generate a Rc<RefCell<Node>>
pub fn push(r: Rc<RefCell<Node>>, c: Rc<RefCell<Node>>)
[src]
Add second tree to the first one.
pub fn remove(&mut self, c: Rc<RefCell<Node>>)
[src]
Delete spefic child using rc
pub fn replace(&mut self, t: Node)
[src]
Replace current tree
pub fn update(&mut self)
[src]
Update tree
Trait Implementations
impl Clone for Node
[src]
impl Debug for Node
[src]
impl Default for Node
[src]
impl PartialEq<Node> for Node
[src]
impl<'t> Serde<Node, String, Error> for Node
[src]
Auto Trait Implementations
impl !RefUnwindSafe for Node
impl !Send for Node
impl !Sync for Node
impl Unpin for Node
impl !UnwindSafe for Node
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,