Debian Codegraph @

src/main/org/h2/expression/function/Function1.java

raw
1 /*
2 * Copyright 2004-2023 H2 Group. Multiple-Licensed under the MPL 2.0,
3 * and the EPL 1.0 (https://h2database.com/html/license.html).
4 * Initial Developer: H2 Group
5 */
6 package org.h2.expression.function;
7
8 import org.h2.expression.Expression;
9 import org.h2.expression.Operation1;
10
11 /**
12 * Function with one argument.
13 */
14 public abstract class Function1 extends Operation1 implements NamedExpression {
15
16 protected Function1(Expression arg) {
17 super(arg);
18 }
19
20 @Override
21 public StringBuilder getUnenclosedSQL(StringBuilder builder, int sqlFlags) {
22 return arg.getUnenclosedSQL(builder.append(getName()).append('('), sqlFlags).append(')');
23 }
24
25 }