private String toString(Predicate p) {
		StringBuilder sb = new StringBuilder();
		if(p instanceof BinaryPredicate) {
			
			sb.append(((BinaryPredicate)p).getA().getName()).append(" ")
				.append(p.getOperator()).append(" ");
			if(p instanceof Exactly) {
				sb.append(((Exactly)p).getNum());
			} else {
				sb.append(((BinaryPredicate)p).getB().getName());
			}
			
		} else if(p instanceof UnaryPredicate) {
			
			sb.append(p.getOperator());
			if(null != ((UnaryPredicate)p).getA()) {
				sb.append(" ").append(((UnaryPredicate)p).getA().getName());
			}
			
		} else if(p instanceof LogicalPredicate) {

			if(p instanceof LogicalNot) {
				sb.append("NOT ").append(
						this.toString(
								((LogicalNot)p).getPredicates().get(0)));
			} else if(p instanceof LogicalOr) {
				
				LogicalOr lop = (LogicalOr)p;
				for(int i=0; i<lop.getPredicates().size(); i++) {
					sb.append(this.toString(lop.getPredicates().get(i)));
					if(i < lop.getPredicates().size() - 1) {
						sb.append(" \\/ ");
					}
				}
			}
		}
		
		
		return sb.toString();
	}