protected function loadDeploymentDescriptors()
    {

        // load the web application base directory
        $webappPath = $this->getApplication()->getWebappPath();

        // load the deployment service
        /** @var \AppserverIo\Appserver\Core\Api\DeploymentService $deploymentService */
        $deploymentService = $this->getApplication()->newService('AppserverIo\Appserver\Core\Api\DeploymentService');

        // prepare the array with the deployment descriptor with the fallback deployment descriptor
        $deploymentDescriptors = array($deploymentService->getConfdDir(sprintf('%s.xml', $descriptorName = $this->getConfiguration()->getDescriptorName())));

        // try to locate deployment descriptors in the configured directories
        foreach ($this->getDirectories() as $directory) {
            // make sure we've a path, relative to the webapp directory
            $strippedDirectory = ltrim(str_replace($webappPath, '', $directory), DIRECTORY_SEPARATOR);

            // add the environment aware deployment descriptor to the array
            array_push(
                $deploymentDescriptors,
                AppEnvironmentHelper::getEnvironmentAwareGlobPattern($webappPath, $strippedDirectory . DIRECTORY_SEPARATOR . $descriptorName)
            );
        }


        // return the loaded deployment descriptors
        return $deploymentDescriptors;
    }
protected function loadDeploymentDescriptors()
    {

        // load the web application base directory
        $webappPath = $this->getApplication()->getWebappPath();

        // load the deployment service
        /** @var \AppserverIo\Appserver\Core\Api\DeploymentService $deploymentService */
        $deploymentService = $this->getApplication()->newService('AppserverIo\Appserver\Core\Api\DeploymentService');

        // prepare the array with the deployment descriptor with the fallback deployment descriptor
        $deploymentDescriptors = array($deploymentService->getConfdDir(sprintf('%s.xml', $descriptorName = $this->getConfiguration()->getDescriptorName())));

        // try to locate deployment descriptors in the configured directories
        foreach ($this->getDirectories() as $directory) {
            // make sure we've a path, relative to the webapp directory
            $strippedDirectory = ltrim(str_replace($webappPath, '', $directory), DIRECTORY_SEPARATOR);

            // add the environment aware deployment descriptor to the array
            array_push(
                $deploymentDescriptors,
                AppEnvironmentHelper::getEnvironmentAwareGlobPattern($webappPath, $strippedDirectory . DIRECTORY_SEPARATOR . $descriptorName)
            );
        }


        // return the loaded deployment descriptors
        return $deploymentDescriptors;
    }
protected function loadDeploymentDescriptors ( ) { // load the web application base directory $ webappPath = $ this -> getApplication ( ) -> getWebappPath ( ) ; // load the deployment service /** @var \AppserverIo\Appserver\Core\Api\DeploymentService $deploymentService */ $ deploymentService = $ this -> getApplication ( ) -> newService ( 'AppserverIo\Appserver\Core\Api\DeploymentService' ) ; // prepare the array with the deployment descriptor with the fallback deployment descriptor $ deploymentDescriptors = array ( $ deploymentService -> getConfdDir ( sprintf ( '%s.xml' , $ descriptorName = $ this -> getConfiguration ( ) -> getDescriptorName ( ) ) ) ) ; // try to locate deployment descriptors in the configured directories foreach ( $ this -> getDirectories ( ) as $ directory ) { // make sure we've a path, relative to the webapp directory $ strippedDirectory = ltrim ( str_replace ( $ webappPath , '' , $ directory ) , DIRECTORY_SEPARATOR ) ; // add the environment aware deployment descriptor to the array array_push ( $ deploymentDescriptors , AppEnvironmentHelper :: getEnvironmentAwareGlobPattern ( $ webappPath , $ strippedDirectory . DIRECTORY_SEPARATOR . $ descriptorName ) ) ; } // return the loaded deployment descriptors return $ deploymentDescriptors ; }
Loads the environment aware deployment descriptors for the given manager.

@return string[] The array with the deployment descriptors
Loads the environment aware deployment descriptors for the given manager .