private void addRuleFiles ( List < RuleSource > sources , File directory ) throws MojoExecutionException { List < RuleSource > ruleSources = readRulesDirectory ( directory ) ; for ( RuleSource ruleSource : ruleSources ) { getLog ( ) . debug ( "Adding rules from file " + ruleSource ) ; sources . add ( ruleSource ) ; } }
Add rules from the given directory to the list of sources .