@param string $name

@throws ApplicationException
519443
public static function removeConfig(string $name): void
    {
        if ($name == 'application') {
            throw new ApplicationException('You\'re not allowed to remove \'application\' config in runtime');
        }

        if (isset(static::$configs[$name])) {
            unset(static::$configs[$name]);
        }
    }
1073578
public function setName($name = '')
    {
        if ('' == $name) {
            $name = 'Growl for Phing';
        }

        if (!is_string($name)) {
            throw new BuildException(
                '"name" attribute is invalid.' .
                ' Expect to be a string, actual is ' . gettype($name)
            );
        }

        $this->name = $name;
    }
1264180
protected function setApplicationName($applicationName)
    {
        if ($applicationName != strtolower($applicationName)) {
            throw new InvalidArgumentException('Application name should be lowercase');
        }
        if (preg_match('/[^a-z0-9]/', $applicationName)) {
            throw new InvalidArgumentException('Application name should contains only alphanumeric chars');
        }

        if (strlen($applicationName) > 16) {
            $message = 'Application name should be no longer than 16 characters';
            throw new InvalidArgumentException($message);
        }

        $this->applicationName = $applicationName;
    }
15658
public function load(string $filename)
    {
        if (!file_exists($filename)) {
            Throw new AppException(sprintf('Languagefile "%s" does not exist.'), $filename);
        }

        $loaded = include $filename;

        if ($loaded) {
            $array = new Flatten($loaded);
            $array->setPreserveFlaggedArraysFlag(true);
            $this->strings = array_replace($this->strings, $array->flatten());
        }
    }
959954
public function getEnvironmentConfiguration(string $name): EnvironmentConfiguration
    {
        if (array_key_exists($name, $this->environmentConfigurations)) {
            return $this->environmentConfigurations[$name];
        }
        throw new DomainException('There is no environment configuration with name' . $name);
    }
1187534
public function setName(string $name = '') : void
    {
        if (empty($name)) {
            throw new RuntimeException('Panel name not found therefore the object cannot be created');
        }
        $this->name = $name;
    }
1124492
public static final void setApplId(byte[] name)
    {
        if (tc.isDebugEnabled())
            Tr.debug(tc, "setApplId", name);

        // Store the applId.
        applId = name;
    }
735853
public function dropView($name)
    {
        if (!$this->hasView($name)) {
            throw SchemaException::schemaViewDoesNotExist($this->getName(), $name);
        }

        unset($this->views[$name]);
    }
378293
public function remove($name)
    {
        try {
            $this->fs->remove($this->rootPath . DIRECTORY_SEPARATOR . 'www' . DIRECTORY_SEPARATOR . 'plugins' . DIRECTORY_SEPARATOR . $name);
        } catch (IOException $e) {
            throw new RuntimeException(
                sprintf('Unable to remove assets for plugin %s', $name), $e->getCode(), $e
            );
        }
    }
141453
public function dropForeignKey($name)
    {
        if (!$this->hasForeignKey($name)) {
            throw SchemaException::tableForeignKeyDoesNotExist($this->getName(), $name);
        }

        unset($this->foreignKeys[$name]);
    }
1120483
public function target($name)
    {
        if (!$this->config->hasTarget($name)) {
            throw new RuntimeException("The target named '$name' does not exist.");
        }
        $ext = $this->config->getExt($name);

        $themed = $this->config->isThemed($name);
        $filters = $this->config->targetFilters($name);
        $target = $this->config->cachePath($ext) . $name;

        $files = [];
        $scanner = $this->scanner($this->config->paths($ext, $name));
        $paths = $scanner->paths();

        $required = $this->config->requires($name);
        if ($required) {
            $compiler = $this->cachedCompiler();
            foreach ($required as $dependency) {
                $files[] = new Target($this->target($dependency), $compiler);
            }
        }

        foreach ($this->config->files($name) as $file) {
            if (preg_match('#^https?://#', $file)) {
                $files[] = new Remote($file);
            } else {
                if (preg_match('/(.*\/)(\*.*?)$/U', $file, $matches)) {
                    $path = $scanner->find($matches[1]);
                    if ($path === false) {
                        throw new RuntimeException("Could not locate folder $file for $name in any configured path.");
                    }
                    $glob = new Glob($path, $matches[2]);
                    $files = array_merge($files, $glob->files());
                } elseif (preg_match(static::CALLBACK_PATTERN, $file, $matches)) {
                    $callback = new Callback($matches[1], $matches[2], $scanner);
                    $files = array_merge($files, $callback->files());
                } else {
                    $path = $scanner->find($file);
                    if ($path === false) {
                        throw new RuntimeException("Could not locate $file for $name in any configured path.");
                    }
                    $files[] = new Local($path);
                }
            }
        }
        return new AssetTarget($target, $files, $filters, $paths, $themed);
    }
699484
public function dropTable($name)
    {
        if (!$this->hasTable($name)) {
            throw SchemaException::schemaTableDoesNotExist($this->getName(), $name);
        }

        unset($this->tables[$name]);
    }
424780
protected function setName($name)
    {
        if (false === is_string($name)) {
            $type = gettype($name);
            throw new ValidationException("Term 'name' must be of type string. Type $type received.");
        }

        $this->name = $name;
    }
1280084
protected function initAppSystem(string $name, string $className)
    {
        if (!class_exists($className)) {
            throw new Exception(
                'The appSystem class '.$className.' not exist.',
                self::ERR_APP_SYSTEM_CLASS_NOT_EXIST
            );
        }
        
        $appSystem = new $className;
        if ($appSystem instanceof SystemInterface === false) {
            throw new Exception(
                'The appSystem '.$className.' not implement the interface.',
                self::ERR_APP_SYSTEM_NOT_IMPLEMENT_INTERFACE
            );
        }
        
        $this->appSystemList[$name] = $appSystem;
        
        if ($appSystem->toRun() === true) {
            $this->runTasks->addToRunSteps(
                $name,
                \BFW\RunTasks::generateStepItem(null, [$appSystem, 'run'])
            );
        }
    }
1156173
public void setNameconflict(String nameconflict) throws ApplicationException {

	this.nameconflict = FileUtil.toNameConflict(nameconflict, NAMECONFLICT_UNDEFINED | NAMECONFLICT_ERROR | NAMECONFLICT_OVERWRITE, NAMECONFLICT_DEFAULT);
    }
907458
public function package(string $name): void
    {
        $files = $this->app->make('files');

        if (\method_exists($this->app, 'vendorPath')) {
            $vendorPath = \rtrim($this->app->vendorPath(), '/');
        } else {
            $basePath = \rtrim($this->app->basePath(), '/');
            $vendorPath = "{$basePath}/vendor";
        }

        $paths = [
            "{$vendorPath}/{$name}/resources/database/migrations/",
            "{$vendorPath}/{$name}/database/migrations/",
            "{$vendorPath}/{$name}/migrations/",
        ];

        foreach ($paths as $path) {
            if ($files->isDirectory($path)) {
                $this->run($path);
            }
        }
    }
675300
public function name(string $name){
		$this->name = trim($name);

		if(empty($this->name)){
			throw new QueryException('no name specified');
		}

		return $this;
	}