public Rule getRule ( int id ) { Rule returnRule = null ; for ( Rule rule : this . getRules ( ) . getRule ( ) ) { if ( rule . getId ( ) == id ) { returnRule = rule ; break ; } } return returnRule ; }
Gets a rule by its id .