Object parent = digester.peek(1);
// Just in case if the parent is a Pattern, otherwise
// ClassNotException thrown.
if (parent instanceof Pattern) {
Operator operator = (Operator) child;
Pattern pattern = (Pattern) parent;
pattern.addCondition(operator);
} else {
Operator operator = (Operator) child;
Operator parentOperator = (Operator) parent;
parentOperator.addCondition(operator);
}
}