1 7 8 package javax.management; 9 10 11 12 19 class OrQueryExp extends QueryEval implements QueryExp { 20 21 22 private static final long serialVersionUID = 2962973084421716523L; 23 24 27 private QueryExp exp1; 28 29 32 private QueryExp exp2; 33 34 35 38 public OrQueryExp() { 39 } 40 41 44 public OrQueryExp(QueryExp q1, QueryExp q2) { 45 exp1 = q1; 46 exp2 = q2; 47 } 48 49 50 53 public QueryExp getLeftExp() { 54 return exp1; 55 } 56 57 60 public QueryExp getRightExp() { 61 return exp2; 62 } 63 64 76 public boolean apply(ObjectName name) throws BadStringOperationException , 77 BadBinaryOpValueExpException , BadAttributeValueExpException , 78 InvalidApplicationException { 79 return exp1.apply(name) || exp2.apply(name); 80 } 81 82 85 public String toString() { 86 return "(" + exp1 + ") or (" + exp2 + ")"; 87 } 88 } 89 | Popular Tags |