[opt](inverted index) Optimize the usage of the multi_match function (#39472)
## Proposed changes https://github.com/apache/doris/pull/39193 <!--Describe your changes.-->
This commit is contained in:
@ -32,33 +32,23 @@ import com.google.common.collect.ImmutableList;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* ScalarFunction 'multi_match'. This class is generated by GenerateFunction.
|
||||
* ScalarFunction 'multi_match'.
|
||||
*/
|
||||
public class MultiMatch extends ScalarFunction
|
||||
implements BinaryExpression, ExplicitlyCastableSignature, AlwaysNotNullable {
|
||||
|
||||
public static final List<FunctionSignature> SIGNATURES = ImmutableList.of(
|
||||
FunctionSignature.ret(BooleanType.INSTANCE)
|
||||
.args(StringType.INSTANCE,
|
||||
StringType.INSTANCE,
|
||||
StringType.INSTANCE,
|
||||
StringType.INSTANCE)
|
||||
FunctionSignature.ret(BooleanType.INSTANCE).varArgs(StringType.INSTANCE)
|
||||
);
|
||||
|
||||
/**
|
||||
* constructor with 4 arguments.
|
||||
*/
|
||||
public MultiMatch(Expression arg0, Expression arg1, Expression arg2, Expression arg3) {
|
||||
super("multi_match", arg0, arg1, arg2, arg3);
|
||||
public MultiMatch(Expression ...varArgs) {
|
||||
super("multi_match", varArgs);
|
||||
}
|
||||
|
||||
/**
|
||||
* withChildren.
|
||||
*/
|
||||
@Override
|
||||
public MultiMatch withChildren(List<Expression> children) {
|
||||
Preconditions.checkArgument(children.size() == 4);
|
||||
return new MultiMatch(children.get(0), children.get(1), children.get(2), children.get(3));
|
||||
Preconditions.checkArgument(children.size() >= 3);
|
||||
return new MultiMatch(children.toArray(new Expression[0]));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user