Get the ExtDirect Api response Remoting descriptor.

@return string;
183648
public function getRemoting()
    {
        $apiStr = sprintf("Ext.app.REMOTING_API =%s;", $this);

        $response = new Response($apiStr);

        // set the response header
        $response->headers->set('Content-Type', 'text/javascript');

        // return the response
        return $response;
    }
1348897
public function getIp(): string
    {
        if ($this->ip === null) {
            foreach (["HTTP_X_FORWARDED_FOR", "X_FORWARDED_FOR"] as $key) {
                $proxyIpList = $this->environment[$key] ?? "";
                if ($proxyIpList) {
                    $commaPosition = strpos($proxyIpList, ",");
                    if ($commaPosition !== false) {
                        $this->ip = substr($proxyIpList, 0, $commaPosition);
                    } else {
                        $this->ip = $proxyIpList;
                    }
                    return $this->ip;
                }
            }
            $this->ip = $this->environment["REMOTE_ADDR"] ?? "";
        }
        return $this->ip;
    }
1329706
public function getWithUriFallback()
    {
        if (($get = $this->export()) !== null) {
            // Host defined by the Host directive
            return $get;
        } elseif ($this->base !== $this->effective &&
            parse_url($this->base, PHP_URL_HOST) === ($host = parse_url($this->effective, PHP_URL_HOST))
        ) {
            // Host is the same, but Scheme or Port is different
            return getservbyname($scheme = parse_url($this->effective, PHP_URL_SCHEME), 'tcp') === parse_url($this->effective, PHP_URL_PORT) ? $scheme . '://' . $host : $this->effective;
        }
        // Return Host name only
        return parse_url($this->effective, PHP_URL_HOST);
    }
717241
private function determineExtension()
    {
        $ext = 'php';
        if (in_array($this->driverClass, $this->extensionToDriver)) {
            $map = array_flip($this->extensionToDriver);
            $ext = $map[$this->driverClass];
        }
        return $ext;
    }
473147
static function getDir($dir = '.', $ext = NULL) {

		if($dir != '') {
			$dir = rtrim($dir, '/').'/';
		}
		try {
			$i = new \DirectoryIterator($dir);
		} catch (\Exception $e) {
			return false;
		}

		$files = array();

		foreach($i as $file) {
			$fn = $file->getFileName();
			if(!$file->isDot() && $file->isFile() && substr($fn, 0, 1) !== '.') {
				if(!isset($ext) || preg_match("~$ext\$~", $fn)) {
					$files[] = $fn;
				}
			}
		}

		return $files;
	}
1103995
public static function rootDir()
    {
        $instance = self::instance();
        if ( !$instance->RootDir )
        {
            $cwd  = getcwd();
            $self  = $instance->serverVariable( 'PHP_SELF' );
            if ( file_exists( $cwd . $instance->FileSeparator . $self ) or
                 file_exists( $cwd . $instance->FileSeparator . $instance->IndexFile ) )
            {
                $instance->RootDir = $cwd;
            }
            else
            {
                $instance->RootDir = null;
            }
        }
        return $instance->RootDir;
    }
55085
public function getDescription()
    {
        $flattened = (array) $this->getStringTask();
        $flattened = implode('/', $flattened);

        return parent::getDescription() ?: $flattened;
    }
549238
protected function getExtensionId()
    {
        $extensionEntity = $this->getExtensionEntity();
        if (isset($extensionEntity)) {
            $extensionEntityId = $extensionEntity->get('id');
        }

        if (!isset($extensionEntityId)) {
            return $this->getProcessId();
        }

        return $extensionEntityId;
    }
735708
public function getRemoteIP(): string
    {
        if (null === $this->remote_ip) {
            $ip = $_SERVER['REMOTE_ADDR'];
            if (!empty($_SERVER['HTTP_X_FORWARDED_FOR'])) {
                $ip = $_SERVER['HTTP_X_FORWARDED_FOR'];
                $ip = explode(',', $ip);
                $ip = trim($ip[0]);
            }
            $this->remote_ip = $ip;
        }
        return $this->remote_ip;
    }
1069571
public function getSelectedAddressId()
    {
        if ($this->_sSelAddressId !== null) {
            return $this->_sSelAddressId;
        }

        $sAddressId = Registry::getConfig()->getRequestParameter("oxaddressid");
        if (!$sAddressId && !Registry::getConfig()->getRequestParameter('reloadaddress')) {
            $sAddressId = Registry::getSession()->getVariable("deladrid");
        }

        return $sAddressId;
    }
254092
public function getRev()
    {
        if ($this->_receive) {
            return $this;
        }
        $postStr = !empty($this->postxml) ? $this->postxml : file_get_contents("php://input");
        if (!empty($postStr)) {
            $disableEntities = libxml_disable_entity_loader(true);
            $this->_receive = (array)simplexml_load_string($postStr, 'SimpleXMLElement', LIBXML_NOCDATA);
            libxml_disable_entity_loader($disableEntities);
        }
        return $this;
    }
357693
public function generateRemotingApi() {
        $list = array();
        foreach($this->remotingBundles as $bundle) {
            $bundleRef = new \ReflectionClass($bundle);
            $controllerDir = new Finder();
            $controllerDir->files()->in(dirname($bundleRef->getFileName()).'/Controller/')->name('/.*Controller\.php$/');
            foreach($controllerDir as $controllerFile) {
                $controller = $bundleRef->getNamespaceName() . "\\Controller\\" . substr($controllerFile->getFilename(), 0, -4);
                $controllerRef = new \ReflectionClass($controller);
                foreach ($controllerRef->getMethods(\ReflectionMethod::IS_PUBLIC) as $method) {
                    /** @var $methodDirectAnnotation Direct */
                    $methodDirectAnnotation = $this->annoReader->getMethodAnnotation($method, 'Tpg\ExtjsBundle\Annotation\Direct');
                    if ($methodDirectAnnotation !== null) {
                        $nameSpace = str_replace("\\", ".", $bundleRef->getNamespaceName());
                        $className = str_replace("Controller", "", $controllerRef->getShortName());
                        $methodName = str_replace("Action", "", $method->getName());
                        $list[$nameSpace][$className][] = array(
                            'name'=>$methodName,
                            'len' => count($method->getParameters())
                        );
                    }
                }
            }
        }
        return $list;
    }
336507
protected function getBatchRedirectUrl() : string
    {
        // default url
        $result = ['plugin' => $this->plugin, 'controller' => $this->name, 'action' => 'index'];

        $currentUrl = $this->request->getEnv('HTTP_ORIGIN') . $this->request->getRequestTarget();
        // if referer does not match current url, redirect to referer (delete action)
        if (false === strpos($this->referer(), $currentUrl)) {
            $result = $this->referer();
        }

        // use batch redirect url if provided (edit action)
        if ($this->request->getData('batch.redirect_url')) {
            $result = $this->request->getData('batch.redirect_url');
        }

        return Router::url($result);
    }
173386
public function getExtendedMessage()
    {
        $info = '';
        foreach ($this->getTrace() as $position) {
            if (isset($position['file'])) {
                $info .= ' ' . $position['file'] . '(' . $position['line'] . '): ' . $position['function'];
            }
        }
        $requestUri = \Mmi\App\FrontController::getInstance()->getEnvironment()->requestUri;
        return $requestUri . ' ' . strip_tags(parent::getMessage() . ': ' . $this->getFile() . '(' . $this->getLine() . ')' . $info);
    }
1138257
protected function getReturnUrl()
	{
	    if($this->getServiceLocator()->has(ReturnUrlService::SERVICE_ID)){
            $deliveryExecution = $this->getCurrentDeliveryExecution();
            return $this->getServiceLocator()->get(ReturnUrlService::SERVICE_ID)->getReturnUrl($deliveryExecution->getIdentifier());
        }
	    return _url('index', 'DeliveryServer', 'taoDelivery');
	}
932099
protected function getClientDirectoryName() {
    return strtolower($this->getEnvironment()->getClient()) . '-' . strtolower($this->getEnvironment()->getName()) . '-' . $this->getConfiguration()->getBranch();
  }
189808
protected function getExtensionManager()
    {
        if ($this->getServiceLocator()->has(common_ext_ExtensionsManager::SERVICE_ID)) {
            $service = $this->getServiceLocator()->get(common_ext_ExtensionsManager::SERVICE_ID);
        } else {
            $service = new common_ext_ExtensionsManager();
            $this->getServiceLocator()->propagate($service);
        }
        return $service;
    }