public function addElement(Element $element) { $this->elementList[$element->getName()] = $element; return $this; }
public function attach(Element $element) { $attribute = new SimpleAttribute('for', $element->getId()); $this->addAttribute($attribute); return $this; }