public static boolean isPresent(Rule rule){
  if (rule == null) {
    return false;
  }
  return (!isNotSet(rule.getMinScaleDenominator()) || !isNotSet(rule.getMaxScaleDenominator()));
}

public static boolean isPresent ( Rule rule ) { if ( rule == null ) { return false ; } return ( ! isNotSet ( rule . getMinScaleDenominator ( ) ) || ! isNotSet ( rule . getMaxScaleDenominator ( ) ) ) ; }
checks if rule has minimum or maximum scale denominator set . returns false if rule is null .
