aboutsummaryrefslogtreecommitdiffstats
path: root/searchlib/src/main/java/com/yahoo/searchlib/expression/OrFunctionNode.java
blob: b9123daa6d3143415f4dfd0814c0787980176b25 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
package com.yahoo.searchlib.expression;

/**
 * This function is an instruction to perform bitwise OR on the result of all arguments.
 *
 * @author baldersheim
 * @author Simon Thoresen Hult
 */
public class OrFunctionNode extends BitFunctionNode {

    public static final int classId = registerClass(0x4000 + 68, OrFunctionNode.class);

    @Override
    protected int onGetClassId() {
        return classId;
    }

    public void onArgument(final ResultNode arg, IntegerResultNode result) {
        result.orOp(arg);
    }
}