private void processRule(final IFlexRule currentRule) {
    LOGGER.fine("Processing " + currentRule.getRuleName() + "...");

    for (final Entry<String, IFlexFile> currentFileEntry : files.entrySet()) {
      processFile(currentRule, currentFileEntry.getValue());
    }
  }
  private void computeRules(final RuleSet ruleSet) {
    LOGGER.info("computing RulesList");

    final long startTime = System.currentTimeMillis();
    Set<String> excludes = new HashSet<String>(ruleSet.getExcludePatterns());

    for (Rule rule : ruleSet.getRules()) {
      while (rule instanceof RuleReference) {
        excludes = ((RuleReference) rule).getRuleSetReference().getExcludes();
        rule = ((RuleReference) rule).getRule();
      }
      final IFlexRule flexRule = (IFlexRule) rule;

      if (excludes != null && !excludes.isEmpty()) {
        flexRule.setExcludes(excludes);
      }
      rules.put(flexRule.getRuleName(), flexRule);
    }

    LOGGER.info("computed RulesList in " + (System.currentTimeMillis() - startTime) + " ms");
  }