private function processSingleTag($item, $filename, $configKey = '')
    {
        if ($item instanceof TaggedValue) {
            $tag = $item->getTag();
            $value = $item->getValue();
        } elseif (is_string($item) && strlen($item) && $item[0] === '!' && preg_match('/\!([a-z]+)[ \t]+(.+)$/i', $item, $matches)) {
            $tag = $matches[1];
            $value = Yaml::parse($matches[2]);
            if (!is_string($value)) {
                return $item;
            }
        } else {
            return $item;
        }

        // Process the '!include' tag. The '!archive' and '!file' tags are
        // ignored as they are not relevant to the CLI (yet).
        switch ($tag) {
            case 'include':
                return $this->resolveInclude($value, $filename, $configKey);
        }

        return $item;
    }
private function processSingleTag($item, $filename, $configKey = '')
    {
        if ($item instanceof TaggedValue) {
            $tag = $item->getTag();
            $value = $item->getValue();
        } elseif (is_string($item) && strlen($item) && $item[0] === '!' && preg_match('/\!([a-z]+)[ \t]+(.+)$/i', $item, $matches)) {
            $tag = $matches[1];
            $value = Yaml::parse($matches[2]);
            if (!is_string($value)) {
                return $item;
            }
        } else {
            return $item;
        }

        // Process the '!include' tag. The '!archive' and '!file' tags are
        // ignored as they are not relevant to the CLI (yet).
        switch ($tag) {
            case 'include':
                return $this->resolveInclude($value, $filename, $configKey);
        }

        return $item;
    }
private function processSingleTag ( $ item , $ filename , $ configKey = '' ) { if ( $ item instanceof TaggedValue ) { $ tag = $ item -> getTag ( ) ; $ value = $ item -> getValue ( ) ; } elseif ( is_string ( $ item ) && strlen ( $ item ) && $ item [ 0 ] === '!' && preg_match ( '/\!([a-z]+)[ \t]+(.+)$/i' , $ item , $ matches ) ) { $ tag = $ matches [ 1 ] ; $ value = Yaml :: parse ( $ matches [ 2 ] ) ; if ( ! is_string ( $ value ) ) { return $ item ; } } else { return $ item ; } // Process the '!include' tag. The '!archive' and '!file' tags are // ignored as they are not relevant to the CLI (yet). switch ( $ tag ) { case 'include' : return $ this -> resolveInclude ( $ value , $ filename , $ configKey ) ; } return $ item ; }
Processes a single config item, which may be a custom tag.

@param mixed  $item
@param string $filename
@param string $configKey

@return mixed
Processes a single config item which may be a custom tag .