Constraints implements Iterable<Constraint> { public static Constraints single(Constraint constraint) { LinkedHashSet<Constraint> set = new LinkedHashSet<>(); set.add(constraint); return new Constraints(set, AND); } private  Constraints(LinkedHashSet<Constraint> constraints, Operator operator); static Constraints single(Constraint constraint); static Constraints and(Constraint first, Constraint... rest); static Constraints and(Iterable<Constraint> constraints); static Constraints or(Constraint first, Constraint... rest); static Constraints or(Iterable<Constraint> constraints); static Constraints empty(); static Constraints parse(String input); @Override String toString(); String data(); @Override Iterator<Constraint> iterator(); int size(); boolean isEmpty(); boolean contains(Object o); Set<Constraint> getConstraints(); Operator getOperator();  }
@Test public void single() { Constraints single = Constraints.single(ENGAGE); assertSingle(single); }