void attach(input, { String name })

Add this node to the given node. If input is a String, it is interpreted as a node path and resolved to a node. If input is a SimpleNode, it will be attached to that.

Source

void attach(input, {String name}) {
  if (name == null) {
    name = this.name;
  }

  if (input is String) {
    provider.getNode(input).addChild(name, this);
  } else if (input is SimpleNode) {
    input.addChild(name, this);
  } else {
    throw "Invalid Input";
  }
}