Add additional extensions to what is already in current scope

@param string|array $extensions One or more extensions to add
@return void
552805
public function addExtensions($extensions)
    {
        $extensions = array_merge($this->_extensions, (array)$extensions);
        $this->_extensions = array_unique($extensions);
    }
402180
public function add_extension( Twig_ExtensionInterface $extension ) {
		$env  = $this->instance();
		$exts = $env->getExtensions();

		if ( isset( $exts[$extension->getName()] ) ) {
			return;
		}

		try {
			$env->addExtension( $extension );
		} catch ( LogicException $e ) {
			return;
		}
	}
854447
public function addExtensions(array $extensions)
	{
		if ($extensions)
		{
			$keys = array_map('snake_case', array_keys($extensions));

			$extensions = array_combine($keys, array_values($extensions));
		}

		$this->extensions = array_merge($this->extensions, $extensions);
	}
1304659
public function addExtensions($extensions)
    {
        foreach ($extensions as $extName) {
            $this->twig->addExtension(is_object($extName) ? $extName : Yii::createObject($extName));
        }
    }
1059560
public function addDefinitions(array $definitions)
    {
        $resource          = new DefinitionResource($definitions);
        $this->definitions = array_merge($resource->getDefinitions(), $this->definitions);
    }
1147838
public function register_extensions() {
		$extensions = func_get_args();

		foreach ( $extensions as $extension ) {
			if ( $extension instanceof Twig_ExtensionInterface ) {
				$this->add_extension( $extension );
			} else if ( is_string( $extension ) && class_exists( $extension ) ) {
				$this->add_extension( new $extension );
			} else {
				foreach ( (array) $extension as $ext ) {
					$this->register_extensions( $ext );
				}
			}
		}
	}
53767
public function setExtensions($extensions)
    {
        $this->_extensions = array();
        $token             = ' ,;';
        $extension         = strtok($extensions, $token);

        while ($extension !== false) {
            $this->_extensions[] = $extension;
            $extension           = strtok($token);
        }

    }
1258251
public function add($items = [])
    {
        if (!is_array($items) || func_num_args() > 1) {
            $items = func_get_args();
        }

        $this->push($this->formatInnerField(null, $items));
    }
162445
private function addNamespaces( $additionalNamespaces )
	{
		// Load any additional namespaces
		foreach ( $additionalNamespaces as $namespaces )
		{
			if ( is_null( $namespaces ) || ! is_array( $namespaces ) )
			{
				continue;
			}

			foreach ( $namespaces as $prefix => $namespace )
			{
				if ( empty( $prefix ) ) continue;
				$this->nsMgr->addNamespace( $prefix, $namespace );
			}
		}
	}
943974
public function setAllowedExtensions($extensions)
    {
        if (is_string($extensions)) {
            $extensions = explode(',', $extensions);
        }

        $this->allowedExtensions = array_map('trim', $extensions);

        return $this;
    }
663608
public void addExtensions(Collection<ExtensionElement> extensions) {
        if (extensions == null) return;
        for (ExtensionElement packetExtension : extensions) {
            addExtension(packetExtension);
        }
    }
742855
public function addExtension($extension)
    {
        /** @var ViewFinderInterface $viewFinder */
        foreach ($this->viewFinders as $viewFinder) {
            try {
                $viewFinder->addExtension($extension);
            } catch (\Exception $e) {
            }
        }
    }
485720
public function setAllowedFileExtensions($fileExtensions)
    {
        $this->allowedFileExtensions = [];

        $token = ' ,;';
        $ext = strtok($fileExtensions, $token);

        while ($ext !== false) {
            $this->allowedFileExtensions[] = $ext;
            $ext = strtok($token);
        }
    }
710275
public function addExtension($extension, $engine, $resolver = null)
	{
		$this->finder->addExtension($extension);

		if (isset($resolver))
		{
			$this->engines->register($engine, $resolver);
		}

		unset($this->extensions[$engine]);

		$this->extensions = array_merge(array($extension => $engine), $this->extensions);
	}
235351
public function addHeaders(array $headers)
    {
        foreach ($headers as $name => $value) {
            $this->headers->add($name, $value);
        }
    }
24510
public void registerExtensions(final Class<?>... extensions) {
        for (Class<?> extension : extensions) {
            register(ConfigItem.Extension, extension);
        }
    }
362376
public function setExtension($extension) {
		$pathinfo = pathinfo($this->pathname);
		
		$pathname = new Text($pathinfo['dirname']);
		if (!empty($pathinfo['dirname'])) {
			$pathname = $pathname->append('/');
		}
		
		$this->init($pathname
			->append($pathinfo['filename'])
			->append('.')
			->append($extension))
		;

		return $this;
	}