/** * Attaches the passed server node. * * @param \AppserverIo\Appserver\Core\Api\Node\ServerNodeInterface $server The server node to attach * * @return void */ public function attachServer(ServerNodeInterface $server) { $this->servers[$server->getPrimaryKey()] = $server; }
/** *This method merges the passed server node into this one. * * @param \AppserverIo\Appserver\Core\Api\Node\ServerNodeInterface $serverNode The server node to merge * * @return void */ public function merge(ServerNodeInterface $serverNode) { // append the certificate nodes found in the passed server node /** @var \AppserverIo\Appserver\Core\Api\Node\CertificateNode $certificate */ foreach ($serverNode->getCertificates() as $certificate) { $this->certificates[] = $certificate; } // append the virtual host nodes found in the passed server node /** @var \AppserverIo\Appserver\Core\Api\Node\VirtualHostNode $virtualHost */ foreach ($serverNode->getVirtualHosts() as $virtualHost) { $this->virtualHosts[] = $virtualHost; } }