public boolean addRules(List<Rule> ruleList){
  for (int i=0; i < ruleList.size(); i++) {
    if (!super.validRule(ruleList.get(i)) || !validRule(ruleList.get(i))) {
      return false;
    }
  }
  this.rules=ruleList;
  return true;
}

public boolean addRules ( List < Rule > ruleList ) { for ( int i = 0 ; i < ruleList . size ( ) ; i ++ ) { if ( ! super . validRule ( ruleList . get ( i ) ) || ! validRule ( ruleList . get ( i ) ) ) { return false ; } } this . rules = ruleList ; return true ; }
add a rulelist as the grammar ' s rule list if all rules in it pass both the restrictions of the parent grammars ( unrestricted and context - sens ) and this grammar ' s restrictions .
