private boolean isTrue(Predicate predicate) {
        if (predicate instanceof BooleanPredicate) {
            return ((BooleanPredicate)predicate).getValue();
        }
        return false;
    }
Simplifies a predicate by collapsing TRUE/FALSE-children into their parents.
E.g. if an AND node has a FALSE child, the entire node is replaced by FALSE.
Replaces single-child AND/OR-nodes with the child.

@author Magnar Nedland
@author bjorncs
predicate-search-core/src/main/java/com/yahoo/search/predicate/optimization/BooleanSimplifier.java