private static void addRules(List<String> batchList,List<Rule> rulesToAdd){
  String addStatement="INSERT INTO " + RULES_TABLE + " ("+ "RULE_NAME, "+ "DESCRIPTION, "+ "RULE) "+ "VALUES ('%s', '%s', '%s')";
  for (  Rule rule : rulesToAdd) {
    batchList.add(String.format(addStatement,rule.getName(),rule.getDescription(),rule.getMembershipRule()));
  }
}

private static void addRules ( List < String > batchList , List < Rule > rulesToAdd ) { String addStatement = "INSERT INTO " + RULES_TABLE + " (" + "RULE_NAME, " + "DESCRIPTION, " + "RULE) " + "VALUES ('%s', '%s', '%s')" ; for ( Rule rule : rulesToAdd ) { batchList . add ( String . format ( addStatement , rule . getName ( ) , rule . getDescription ( ) , rule . getMembershipRule ( ) ) ) ; } }
the sql commands to be added to the batchlist for adding the rules in rulestoadd .
