Neos.ContentRepository/Classes/Domain/Repository/NodeDataRepository.php
public function add($object)
    {
        if ($this->removedNodes->contains($object)) {
            $this->removedNodes->detach($object);
        }
        if (!$this->addedNodes->contains($object)) {
            $this->addedNodes->attach($object);
        }
        parent::add($object);
    }
public function add($object)
    {
        if ($this->removedNodes->contains($object)) {
            $this->removedNodes->detach($object);
        }
        if (!$this->addedNodes->contains($object)) {
            $this->addedNodes->attach($object);
        }
        parent::add($object);
    }
public function add ( $ object ) { if ( $ this -> removedNodes -> contains ( $ object ) ) { $ this -> removedNodes -> detach ( $ object ) ; } if ( ! $ this -> addedNodes -> contains ( $ object ) ) { $ this -> addedNodes -> attach ( $ object ) ; } parent :: add ( $ object ) ; }
Adds a NodeData object to this repository.

This repository keeps track of added and removed nodes (additionally to the other Unit of Work)
in order to find in-memory nodes.

@param object $object The object to add
@return void
@api
Adds a NodeData object to this repository .