Checks if a TimePoint matches the criteria
@param array $tags
@param int $target
@param int $type
@return bool
434396
public function match(array $tags = null, $target = self::TARGET_ALL, $type = self::TYPE_ALL)
    {
        $match = ($this->getType() & $type) && ($this->getTarget() & $target);
        
        if ($match && isset($tags)) {
            $match = (count(array_intersect($tags, $this->getTags())) == count($tags));
        }
        
        return $match;
    }
1154476
@java.lang.SuppressWarnings({ "UnnecessaryBoxing" })
    public boolean containsTag(int tagType)
    {
        return _tagMap.containsKey(Integer.valueOf(tagType));
    }
809926
public function bindParam($tag, &$param, $type = DB::PARAM_AUTO) {
        if (!is_int($tag) and ctype_digit($tag))
            $tag = intval($tag);
        elseif (is_string($tag)) {
            if (':' != substr($tag, 0, 1))
                $tag = ":$tag";
        } else
            return false;
        $this->parameters[$tag] = array('param' => &$param, 'type' => $type);
        return true;
    }
860573
private function _hasMatchingTarget(Targets $targets): bool
    {
        foreach ($this->_config->targets() as $target) {
            if ($targets->hasTarget($target)) {
                return true;
            }
        }
        return false;
    }
1123046
protected function hasValidValues(array $values, Type $type): bool
    {
        foreach ($values as $value) {
            if (
                null !== $value
                && Type::BUILTIN_TYPE_INT === $type->getBuiltinType()
                && false === filter_var($value, FILTER_VALIDATE_INT)
            ) {
                return false;
            }
        }

        return true;
    }
1138173
public static function clearTags(array $tags): bool
    {
        if (self::getInstance() instanceof HierarchicalPoolInterface) {
            return self::getInstance()->invalidateTags($tags);
        }
        return false;
    }
836211
protected function matchParentType(
        /*# string */ $childType,
        array $typesToCheck,
        array &$result
    )/*# : bool */ {
        foreach ($typesToCheck as $type) {
            if ($this->isAType($childType) &&
                is_a($childType, $type, true)
            ) {
                $result[$type] = true;
            }
        }
    }
766031
public function isMonitoring(array $tags)
    {
        if (is_null($this->monitoredTags)) {
            $this->loadMonitoredTags();
        }

        return count(array_intersect($tags, $this->monitoredTags)) > 0;
    }
1161905
protected function classMetadataExists($type)
    {
        $className = $this->getClassNameForType($type);
        try {
            $metadata = $this->mf->getMetadataFor($className);
            return true;
        } catch (MappingException $e) {
            return false;
        }
        return false === $this->shouldFilterClassMetadata($metadata);
    }
321782
protected function getTimestamps($cache, $tags)
    {
        if (empty($tags)) {
            return [];
        }

        $keys = [];
        foreach ($tags as $tag) {
            $keys[] = $cache->buildKey([__CLASS__, $tag]);
        }

        return $cache->mget($keys);
    }
531747
private function prepareTargetsForType(?array $targets, LimitationType $type): ?array
    {
        $isTargetAware = $type instanceof TargetAwareType;

        // BC: null for empty targets is still expected by some Limitations, so needs to be preserved
        if (null === $targets) {
            return $isTargetAware ? [] : null;
        }

        // BC: for TargetAware Limitations return only instances of Target, for others return only non-Target instances
        $targets = array_filter(
            $targets,
            function ($target) use ($isTargetAware) {
                $isTarget = $target instanceof Target;

                return $isTargetAware ? $isTarget : !$isTarget;
            }
        );

        // BC: treat empty targets after filtering as if they were empty the whole time
        if (!$isTargetAware && empty($targets)) {
            return null;
        }

        return $targets;
    }
1350222
protected function invalidateCache(array $tags, $time = null)
    {
        if ($this->_cache) {
            $this->_cache->invalidateTags($tags, $time);
        }

        return $this;
    }
1352046
public function hasTags(array $tags, $matchAll = true)
    {
        $routeTags = $this->getRoute()->getTags();
        $diffCount = count(array_diff($tags, $routeTags));
        $tagsCount = count($tags);

        if ($matchAll) {
            if ($diffCount === 0) {
                return true;
            }
        } else {
            if ($tagsCount > $diffCount) {
                return true;
            }
        }

        return false;
    }
1023501
public function invalidateTags(array $tags)
    {
        if (!$this->cache instanceof TagAwareAdapterInterface) {
            throw new \RuntimeException('Cannot invalidate tags on a cache
            implementation that does not implement the TagAwareAdapterInterface.');
        }

        try {
            return $this->cache->invalidateTags($tags);
        } catch (InvalidArgumentException $e) {
            return false;
        }
    }
1171055
function(target){
            // skip valid type check if value evaluating to false or empty array.
            if(!this.validTypes || !this.validTypes.length){
                return true;
            }

            for(var i = this.validTypes.length - 1; i >= 0; i--){
                var type = this.validTypes[i];
                if(target instanceof type){
                    return true;
                }
            }

            // no valid type match found
            return false;
        }
443560
public function isFresh(AssetTarget $target)
    {
        $buildName = $this->buildFileName($target);
        $buildFile = $this->outputDir($target) . DIRECTORY_SEPARATOR . $buildName;

        if (!file_exists($buildFile)) {
            return false;
        }
        $buildTime = filemtime($buildFile);

        if ($this->configTime && $this->configTime >= $buildTime) {
            return false;
        }

        foreach ($target->files() as $file) {
            $time = $file->modifiedTime();
            if ($time === false || $time >= $buildTime) {
                return false;
            }
        }

        $filters = $this->filterRegistry->collection($target);
        foreach ($filters->filters() as $filter) {
            foreach ($filter->getDependencies($target) as $child) {
                $time = $child->modifiedTime();
                if ($time >= $buildTime) {
                    return false;
                }
            }
        }
        return true;
    }
1218888
public function hasShortcode(string $content, $tags = []): bool
    {
        $tags = $this->preProcessTags($tags);
        $matches = $this->parser->parseShortcode($content, $tags);

        return !empty($matches);
    }