Manually check if passed marks matches the marksFilter.

@param array $marks

@return bool
491105
public function matchesMarks(array $marks)
    {
        if (!$this->markFilter) {
            return true;
        }

        foreach ($this->markFilter as $mark => $mustBe) {

            // $mustBe has to be boolean or string, for performance reasons
            // it will not be checked again here

            if ($mustBe === true) {
                if (!isset($marks[$mark]) || !$marks[$mark]) {
                    return false;
                }
            }

            if ($mustBe === false) {
                if (!isset($marks[$mark])) {
                    continue;
                }
                if ((bool)$marks[$mark]) {
                    return false;
                }
            }

            // $mustBe cannot be boolean until here

            $shouldMatch = true;

            if (strpos($mustBe, '!') === 0) {
                $mustBe = substr($mustBe, 1);
                $shouldMatch = false;
            }

            if (!isset($marks[$mark]) && $shouldMatch) {
                return false;
            }

            if (!isset($marks[$mark]) && !$shouldMatch) {
                continue;
            }

            if ( ($marks[$mark] == $mustBe) !== $shouldMatch) {
                return false;
            }

        }

        return true;
    }
733938
public function isMarked($marker)
	{
		if(empty($this->markers))
		{
			return false;
		}
		
		if($marker instanceof \ReflectionClass)
		{
			foreach($this->markers as $check)
			{
				if($marker->isInstance($check))
				{
					return true;
				}
			}
		}
		elseif($marker instanceof Marker)
		{
			foreach($this->markers as $check)
			{
				if($marker->isInstance($check))
				{
					return true;
				}
			}
		}
		else
		{
			foreach($this->markers as $check)
			{
				if($check instanceof $marker)
				{
					return true;
				}
			}
		}
		
		return false;
	}
18728
protected static function _profilerFormatMark(array $mark)
    {
        return sprintf("%0.3f sec (+%.3f); %0.3f MB (%s%0.3f) - %s",
            (float)$mark['time'],
            (float)$mark['timeDiff'],
            ($mark['memory'] / 1024 / 1024),
            ($mark['memoryDiff'] / 1024 / 1024 >= 0) ? '+' : '',
            ($mark['memoryDiff'] / 1024 / 1024),
            $mark['label']
        );
    }
467349
public function hasProfile($profiles) : bool
    {
        $profiles = (array) $profiles;

        return count(array_intersect($this->profiles->pluck('code')->toArray(), $profiles)) > 0;
    }
1110129
protected function checkParsedMark($mark, $value)
    {
        if (strpos($mark, '!') === 0) {
            throw new InvalidArgumentException("Leading ! cannot be used in associative marks.");
        }

        if (!is_bool($value) && !is_string($value)) {
            throw new UnsupportedParameterException("This MatchingListener can only match boolean and strings. You added for $mark a value of " . Type::of($value));
        }
    }
647527
public function match(array $data): bool
    {
        $result = $this->checkMatchArray($data, $this->matchArray);
        if ($result && isset($data['fieldConfig']['config']['foreign_table'])) {
            $result = true;
        } else {
            $result = false;
        }
        return $result;
    }
144931
protected function isTagsMatchCondition($tags)
    {
        $satisfies = true;

        foreach (explode('&&', $this->filterString) as $andTags) {
            $satisfiesComma = false;

            foreach (explode(',', $andTags) as $tag) {
                $tag = str_replace('@', '', trim($tag));

                if ('~' === $tag[0]) {
                    $tag = mb_substr($tag, 1, mb_strlen($tag, 'utf8') - 1, 'utf8');
                    $satisfiesComma = !in_array($tag, $tags) || $satisfiesComma;
                } else {
                    $satisfiesComma = in_array($tag, $tags) || $satisfiesComma;
                }
            }

            $satisfies = (false !== $satisfiesComma && $satisfies && $satisfiesComma) || false;
        }

        return $satisfies;
    }
710075
public function matches( $prefix ) {

		global $wpdb;

		$prefix = esc_sql( $prefix ) . '%';

		$tables = $wpdb->get_col( $wpdb->prepare( 'SHOW TABLES LIKE %s', $prefix ) );

		if ( 0 === count( $tables ) ) {
			return true;
		}

		$this->prefixed_tables = $tables;

		return false;
	}
741024
private function matchVersion(array $array)
    {
        if (!isset($array["version"])) {
            return true;
        }

        if (is_array($array["version"])) {
            foreach ($array["version"] as $version)
            {
                if ($version == $this->getVersion() || $version == "*") {
                    return true;
                }
            }
        } elseif (is_string($array["version"])) {
            if ($array["version"] == $this->getVersion() || $array["version"] == "*") {
                return true;
            }
        }

        return false;
    }
254063
public function matchesPackage(array $array) {
		if (isset($array['package']) && $array['package'] == $this->package->getName()
				&& isset($array['class']) && $array['class'] == $this->getClassName()) {
			return true;
		} else {
			return false;
		}
	}
1117240
public function matchArray(array $tokens, $reset = true)
    {
        if ($reset) {
            $this->reset();
        }
        foreach ($tokens as $t) {
            if (!$this->match($t)) {
                return false;
            }
        }
        return true;
    }
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;
    }
1300487
public function matches($url, array $annotations)
	{
		foreach ( $annotations as $annotation ) {
			if ( preg_match($annotation->regexp, $url) ) {
				return true;
			}
		}

		return false;
	}
831585
public function containsAttributes(array $attributes)
    {
        foreach ($attributes as $attribute) {
            if (!$this->attributes->contains($attribute)) {
                return false;
            }
        }

        return true;
    }
853419
public static function matchTagsWithSortOrder(array $tags1, array $tags2)
    {
        if (count(self::diffTags($tags1, $tags2, true)) == 0 &&
            count(self::diffTags($tags2, $tags1, true)) == 0)
            return true;

        return false;

    }
1257308
public function match($string, array &$matches = null)
    {
        return $this->filter === false || (\preg_match($this->pattern, $string, $matches) xor $this->invert);
    }
1131442
public function apply(array &$tokens)
		{
		for ($i = 0, $l = count($tokens); $i < $l; $i++)
			{
			$current	= get_class($tokens[$i]);
			$next		= isset($tokens[$i+1]) ? get_class($tokens[$i+1]) : false;
			if (($current === "CssRulesetDeclarationToken" && $next === "CssRulesetEndToken") ||
				($current === "CssAtFontFaceDeclarationToken" && $next === "CssAtFontFaceEndToken") || 
				($current === "CssAtPageDeclarationToken" && $next === "CssAtPageEndToken"))
				{
				$tokens[$i]->IsLast = true;
				}
			}
		return 0;
		}