private PackageSet parsePattern() throws ParsingException {
      String scope = null;
      PackageSetParserExtension usedExtension = null;
      for (PackageSetParserExtension extension : PackageSetParserExtension.EP_NAME.getExtensionList()) {
        scope = extension.parseScope(myLexer);
        if (scope != null) {
          usedExtension = extension;
          break;
        }
      }
      if (scope == null) error("Unknown scope type");
      String modulePattern = parseModulePattern();

      if (myLexer.getTokenType() == ScopeTokenTypes.COLON) {
        myLexer.advance();
      }
      final PackageSet packageSet = usedExtension.parsePackageSet(myLexer, scope, modulePattern);
      if (packageSet != null) return packageSet;
      error("Unknown scope type");
      return null; //not reachable
    }
private PackageSet parsePattern()