Set second level domain like `example` from `www.example.com`.
Method also change server name and host record automatically.
@param string|NULL $thirdLevelDomain
@return \MvcCore\Request|\MvcCore\IRequest
328346
public function & SetThirdLevelDomain ($thirdLevelDomain) {
		/** @var $this \MvcCore\Request */
		if ($this->domainParts === NULL) $this->initDomainSegments();
		$this->domainParts[0] = $thirdLevelDomain;
		$this->hostName = trim(implode('.', $this->domainParts), '.');
		if ($this->hostName && $this->portDefined) 
			$this->host = $this->hostName . ':' . $this->port;
		$this->domainUrl = NULL;
		$this->baseUrl = NULL;
		$this->requestUrl = NULL;
		$this->fullUrl = NULL;
		return $this;
	}
1015158
private function setDomainName(?string $domainName): self
    {
        $this->updatePropertyValue(
            DomainNameFieldInterface::PROP_DOMAIN_NAME,
            $domainName
        );

        return $this;
    }
568538
public static function fullUrl($url, $domain = null)
    {
        if (!preg_match('/^https?:\/\//i', $url)) {
            // Fix for root page link
            if ($url === '/') {
                $url = '';
            }

            // remove first /
            if (strpos($url, '/') === 0) {
                $url = substr($url, 1);
            }

            if ($domain !== null) {
                // specified domain
                $url = 'http://' . $domain . '/' . $url;
            } else {
                // domain from env
                $url = Typo3GeneralUtility::getIndpEnv('TYPO3_SITE_URL') . $url;
            }
        }

        // Fix url stuff
        $url = str_replace('?&', '?', $url);

        return $url;
    }
1068454
public function setChildOf(Tree $parent)
    {
        if ($parent->type->name !== 'category') {
            throw new DomainException("Content can be assigned only to category parent");
        }
        return parent::setChildOf($parent);
    }
631988
public function setError($descriptor, $domain = null)
    {
        $this->adapter->setDomain($domain);
        $this->addError($this->adapter->getDescription($descriptor), $this->adapter->getCode($descriptor));
        return $this;
    }
217514
public function setPrimaryDomain($primaryDomain)
    {
        if (empty($primaryDomain)) {
            $this->primaryDomain = null;
            $this->primaryId = null;

            return;
        }

        $this->primaryDomain = $primaryDomain;
        $this->primaryId = $primaryDomain->getDomainId();
    }
192629
function setName($name)
    {
        $selfCurrName = $this->getName();

        if ($name == $selfCurrName)
            // Nothing To Do!!!
            return $this;


        # Change Route Name:
        $this->name = (string) $name;


        ## Change Name of Nested Routes:
        #
        /** @var iRoute $route */
        foreach($this->_priorityQueue() as $route) {
            $nestedName    = $route->getName();
            $nestedNewName = $name. substr($nestedName, strlen($selfCurrName));

            $route->setName($nestedNewName);

            $nr = $this->routesAdd[$nestedName];
            $nr->setName($nestedNewName);

            unset( $this->routesAdd[$nestedName] );
            $this->routesAdd[$nestedNewName] = $nr;
        }


        return $this;
    }
793038
public function withPayloads($first, $second, $third, $fourth)
    {
        $this->payloads = [
            'payload1' => $first,
            'payload2' => $second,
            'payload3' => $third,
            'payload4' => $fourth,
        ];

        return $this;
    }
839800
protected function getPrimaryDomain($domain)
    {
        /** @var \Rcm\Entity\Domain $domain */
        $domain = $this->_em->getRepository(\Rcm\Entity\Domain::class)
            ->findOneBy(['domain' => $domain]);

        if (empty($domain)) {
            return null;
        }

        $primary = $domain->getPrimary();

        if (!$primary->getPrimary()) {
            return $primary;
        }

        return $this->getPrimaryDomain($primary->getDomainName());
    }
249834
function setDomain()
    {
        $this->domains = func_get_args();
        $this->removeDNProp('id-at-commonName');
        $this->setDNProp('id-at-commonName', $this->domains[0]);
    }
854210
public function setDomain(Domain $domain)
    {
        $this->domain = $domain;
        $this->domainId = $domain->getDomainId();
    }
435944
public function setPrimaryDomain(Domain $domain = null)
    {
        if ($domain === null) {
            $this->primaryDomain = null;
            return;
        }

        if (!$domain->getActive()) {
            return;
        }

        $this->primaryDomain = $domain;
        if (!$this->domains->contains($domain)) {
            $this->domains->add($domain);
        }
    }
964084
public static function specifyType($domain)
    {
        if (false !== filter_var($domain, FILTER_VALIDATE_IP)) {
            return new IPAddress($domain);
        }

        return new Hostname($domain);
    }
650980
public function getDomain() : ?string 
    {
        if ( ! $this->hasDomain()) {
            $this->setDomain($this->getDefaultDomain());
        }
        return $this->domain;
    }
979798
public function setRedirectUrl($sRedirectUrl)
    {
        if (!$this->bIsLocked) {
            $this->sRedirectUrl = $sRedirectUrl;
            $this->setIsRedirect(!empty($sRedirectUrl));
        }
        return $this;
    }
349193
public function allowOrigin($domain)
    {
        $allowed = $this->_normalizeDomains((array)$domain);
        foreach ($allowed as $domain) {
            if (!preg_match($domain['preg'], $this->_origin)) {
                continue;
            }
            $value = $domain['original'] === '*' ? '*' : $this->_origin;
            $this->_headers['Access-Control-Allow-Origin'] = $value;
            break;
        }

        return $this;
    }
181392
public function changeDNSDomainRecord($domain, $recordId, $val, $priority)
    {
        return $this->send('v-change-dns-record', $this->userName, $domain, $recordId, $val,
            $priority);
    }