Returns the array of meta tags.

@param string $tagName
@param array $params

@throws \eZ\Publish\API\Repository\Exceptions\InvalidArgumentException If number of params is incorrect

@return \Netgen\Bundle\OpenGraphBundle\MetaTag\Item[]
336073
public function getMetaTags($tagName, array $params = array())
    {
        if (!isset($params[0])) {
            throw new InvalidArgumentException(
                '$params[0]',
                'Field type handlers require at least a field identifier.'
            );
        }

        $fieldIdentifiers = is_array($params[0]) ? $params[0] : array($params[0]);
        $fieldValue = $this->getFallbackValue($tagName, $params);

        foreach ($fieldIdentifiers as $fieldIdentifier) {
            $field = $this->validateField($fieldIdentifier);

            try {
                $fieldValue = $this->getFieldValue($field, $tagName, $params);
                break;
            } catch (FieldEmptyException $e) {
                // do nothing
            }
        }

        return array(
            new Item(
                $tagName,
                $fieldValue
            ),
        );
    }
1114443
public function getPropertyByTagName($tagName, $highest = true)
    {
        if (array_key_exists($tagName, $this->tags)) {
            return $this->tags[$tagName][true === $highest ? 'highest' : 'lowest'];
        } else {
            throw new NoSuchPropertyException($tagName);
        }
    }
1069081
public function getPropertiesByTagName($tagName)
    {
        $properties = [];

        foreach ($this->properties as $property) {
            foreach ($property->tags as $tag) {
                if ($tag['name'] == $tagName) {
                    $properties[$property->name] = $property;
                }
            }
        }

        return $properties;
    }
481885
public function deleteByTag($params, $optParams = [])
    {
        if (is_string($params)) {
            $params = ['tag' => $params];
        }

        return $this->sendRequest(['cloudId', 'tag'], [
            'restAction' => 'delete',
            'uri' => '/c/<cloudId>/t/<tag>',
            'params' => $params,
            'getParams' => $optParams,
        ], function ($response) {
            return isset($response->data) ? new Job($response->data) : $response;
        });
    }
813488
public function findByTag($tag, $params = array(), $options = array())
    {
        $path = sprintf("/tags/%s/tasks", $tag);
        return $this->client->getCollection($path, $params, $options);
    }
877773
public function scopeWithAllTags($query, $tagNames)
	{
		if(!is_array($tagNames)) {
			$tagNames = func_get_args();
			array_shift($tagNames);
		}
		$tagNames = static::$taggingUtility->makeTagArray($tagNames);

		$model = static::$taggingUtility->tagModelString();
		$tagids = $model::byTagNames($tagNames)->lists('id')->all();

		$className = $query->getModel()->getMorphClass();
		$primaryKey = $this->getKeyName();

		$tagid_count = count($tagids);
		if ($tagid_count > 0) {
			$ids = Tagged::where('taggable_type', $className)
							->whereIn('tag_id', $tagids)
							->whereRaw('`tag_id` in (' .implode(',', $tagids). ') group by taggable_id having count(taggable_id) ='.$tagid_count)
							->lists('taggable_id');

			$query->whereIn($this->getTable().'.'.$primaryKey, $ids);
		}

		return $query;
	}
492909
public function getTagNames(Taggable $resource)
    {
        $names = array();

        if (sizeof($resource->getTags()) > 0) {
            foreach ($resource->getTags() as $tag) {
                $names[] = $tag->getName();
            }
        }

        return $names;
    }
133113
public function _foreach($tag,$content) {
        $name       =   $tag['name'];
        $item       =   $tag['item'];
        $key        =   !empty($tag['key'])?$tag['key']:'key';
        $name       =   $this->autoBuildVar($name);
        $parseStr   =   '<?php if(is_array('.$name.')): foreach('.$name.' as $'.$key.'=>$'.$item.'): ?>';
        $parseStr  .=   $this->tpl->parse($content);
        $parseStr  .=   '<?php endforeach; endif; ?>';

        if(!empty($parseStr)) {
            return $parseStr;
        }
        return ;
    }
350533
protected function getTags($term)
    {
        $items = [];
        foreach ($this->getOptions() as $i => $tag) {
            /** @var ArrayData $tag */
            $tagValue = $tag->Value;
            // Map into a distinct list (prevent duplicates)
            if (stripos($tagValue, $term) !== false && !array_key_exists($tagValue, $items)) {
                $items[$tagValue] = [
                    'id' => $tag->Title,
                    'text' => $tag->Value,
                ];
            }
        }
        // @todo do we actually need lazy loading limits for StringTagField?
        return array_slice(array_values($items), 0, $this->getLazyLoadItemLimit());
    }
1341842
private function getCacheTags($tagId, $pathString, array $tags = [])
    {
        $tags[] = 'tag-' . $tagId;

        foreach (explode('/', trim($pathString, '/')) as $pathId) {
            $tags[] = 'tag-path-' . $pathId;
        }

        return $tags;
    }
1037347
public static function URL($name, $params = []){
      return ($r = static::tagged($name)) ? $r-> getURL($params) : new URL();
    }
1301567
private function buildItems(array $tags): array
    {
        return array_map(
            function (Tag $tag): Item {
                return $this->buildItem($tag);
            },
            $tags
        );
    }
1234301
protected function getElements($tagName)
	{
		$nodes = [];
		foreach ($this->template->ownerDocument->getElementsByTagName($tagName) as $node)
		{
			if (!$this->onlyIfDynamic || $this->isDynamic($node))
			{
				$nodes[] = $node;
			}
		}

		return $nodes;
	}
215798
public function getTags($name = null)
  {
    if (!$name) return $this->tags;
    
    return isset($this->tags[$name]) ? $this->tags[$name] : [];
  }
924257
private function convertToTagDoc(TagDoc $tag) : array
    {
        $tagArray = ['name' => $tag->getName()];

        $tagArray = $this->appendIfValueNotNull('description', $tag->getDescription(), $tagArray);

        return $tagArray;
    }
105286
public function getElementByTagName($tagName)
    {
        if (null === $this->treeRoot){
            return array();
        }
        $children = $this->treeRoot->getChildren();

        return $this->getElementByTagInChildren($children, $tagName);
    }
673790
private function findTokensForTag(string $tagName): array
    {
        $allTags = $this->getAllTags();

        return array_filter($allTags, function (array $tag) use ($tagName): bool {
            return substr($tag['content'], 1) === $tagName;
        });
    }