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;
    }