public static double evaluate(double[] values, int startOffset, Context context) {
        int pc = startOffset;
        while (true) {
            double nextValue = values[pc++];
            if (nextValue >= MAX_LEAF_VALUE) { // a condition node
                int offset = (int)nextValue - MAX_LEAF_VALUE;
                boolean comparisonIsTrue = false;
                if (offset < MAX_VARIABLES) {
                    comparisonIsTrue = context.getDouble(offset) < values[pc++];
                }
                else if (offset < MAX_VARIABLES * 2) {
                    comparisonIsTrue = context.getDouble(offset - MAX_VARIABLES) == values[pc++];
                }
                else if (offset < MAX_VARIABLES * 3) {
                    double testValue = context.getDouble(offset - MAX_VARIABLES * 2);
                    int setValuesLeft = (int)values[pc++];
                    while (setValuesLeft > 0) { // test each value in the set
                        setValuesLeft--;
                        if (testValue == values[pc++]) {
                            comparisonIsTrue=true;
                            break;
                        }
                    }
                    pc += setValuesLeft; // jump to after the set
                }
                else { // offset<MAX_VARIABLES*4
                    comparisonIsTrue = ! (context.getDouble(offset - MAX_VARIABLES * 3) >= values[pc++]);
                }

                if (comparisonIsTrue)
                    pc++; // true branch - skip the jump value
                else
                    pc += (int)values[pc]; // false branch - jump
            }
            else { // a leaf
                return nextValue;
            }
        }
    }
Returns a direct reference to the values of this. The returned array must not be modified.
searchlib/src/main/java/com/yahoo/searchlib/rankingexpression/evaluation/gbdtoptimization/GBDTNode.java