protected function matchClass($array, $group, $alias, $class)
    {
        $match = false;

        foreach ($array as $test) {
            if ('path' === $group) {
                $match = 0 === strpos($class, $test);
            } else {
                $match = $test . '\\' . $alias === $class;
            }

            if ($match) {
                break;
            }
        }

        return $match;
    }