if (q == null)
result = Boolean.TRUE;
else {
visit(q);
if (q instanceof EOOrQualifier) {
EOOrQualifier aq = (EOOrQualifier) q;
if (!postOrder) {
result = traverseOrQualifier(aq) ? Boolean.TRUE : Boolean.FALSE;
}
if (result == null || result.booleanValue()) {
for (Enumeration e = aq.qualifiers().objectEnumerator(); e.hasMoreElements();) {
if (!traverseQualifier((EOQualifierEvaluation) e.nextElement(), postOrder)) {
result = Boolean.FALSE;
break;
}
}
}
if (postOrder && (result == null || result.booleanValue())) {
result = traverseOrQualifier(aq) ? Boolean.TRUE : Boolean.FALSE;
}
}
else if (q instanceof EOAndQualifier) {
EOAndQualifier aq = (EOAndQualifier) q;
if (!postOrder) {
result = traverseAndQualifier(aq) ? Boolean.TRUE : Boolean.FALSE;
}
if (result == null || result.booleanValue()) {
for (Enumeration e = aq.qualifiers().objectEnumerator(); e.hasMoreElements();) {
if (!traverseQualifier((EOQualifierEvaluation) e.nextElement(), postOrder)) {
result = Boolean.FALSE;
break;
}
}
}
if (postOrder && (result == null || result.booleanValue())) {
result = traverseAndQualifier(aq) ? Boolean.TRUE : Boolean.FALSE;
}
}
else if (q instanceof EONotQualifier) {
EONotQualifier aq = (EONotQualifier) q;
if (!postOrder) {
result = traverseNotQualifier(aq) ? Boolean.TRUE : Boolean.FALSE;
}
if (result == null || result.booleanValue()) {
result = traverseQualifier((EOQualifierEvaluation) aq.qualifier(), postOrder) ? Boolean.TRUE : Boolean.FALSE;
}
if (postOrder && (result == null || result.booleanValue())) {
result = traverseNotQualifier(aq) ? Boolean.TRUE : Boolean.FALSE;
}
}