[jOOQ/jOOQ#14711] Add missing set(String, Param) and setLocal(String, Param) overloads

This commit is contained in:
Lukas Eder 2023-02-27 09:36:16 +01:00
parent 42e8590d9f
commit add0a771d8
3 changed files with 66 additions and 0 deletions

View File

@ -11024,6 +11024,17 @@ public interface DSLContext extends Scope {
@Support({ HSQLDB, POSTGRES, YUGABYTEDB })
RevokeOnStep revokeGrantOptionFor(Collection<? extends Privilege> privileges);
/**
* The <code>SET</code> statement.
* <p>
* Set a vendor specific session configuration to a new value.
*
* @see DSL#set(String, Param)
*/
@NotNull @CheckReturnValue
@Support({ MARIADB, MYSQL, POSTGRES, YUGABYTEDB })
RowCountQuery set(@Stringly.Name String name, Param<?> value);
/**
* The <code>SET</code> statement.
* <p>
@ -11035,6 +11046,17 @@ public interface DSLContext extends Scope {
@Support({ MARIADB, MYSQL, POSTGRES, YUGABYTEDB })
RowCountQuery set(Name name, Param<?> value);
/**
* The <code>SET LOCAL</code> statement.
* <p>
* Set a vendor specific transaction-local configuration to a new value.
*
* @see DSL#setLocal(String, Param)
*/
@NotNull @CheckReturnValue
@Support({ POSTGRES, YUGABYTEDB })
RowCountQuery setLocal(@Stringly.Name String name, Param<?> value);
/**
* The <code>SET LOCAL</code> statement.
* <p>

View File

@ -10001,6 +10001,23 @@ public class DSL {
return dsl().revokeGrantOptionFor(privileges);
}
/**
* The <code>SET</code> statement.
* <p>
* Set a vendor specific session configuration to a new value.
* <p>
* Unlike statement construction methods in the {@link DSLContext} API, this
* creates an unattached, and thus not directly renderable or executable
* statement. It can be used as a subquery or nested in procedural logic.
*
* @see DSLContext#set(String, Param)
*/
@NotNull @CheckReturnValue
@Support({ MARIADB, MYSQL, POSTGRES, YUGABYTEDB })
public static org.jooq.RowCountQuery set(@Stringly.Name String name, Param<?> value) {
return dsl().set(name, value);
}
/**
* The <code>SET</code> statement.
* <p>
@ -10018,6 +10035,23 @@ public class DSL {
return dsl().set(name, value);
}
/**
* The <code>SET LOCAL</code> statement.
* <p>
* Set a vendor specific transaction-local configuration to a new value.
* <p>
* Unlike statement construction methods in the {@link DSLContext} API, this
* creates an unattached, and thus not directly renderable or executable
* statement. It can be used as a subquery or nested in procedural logic.
*
* @see DSLContext#setLocal(String, Param)
*/
@NotNull @CheckReturnValue
@Support({ POSTGRES, YUGABYTEDB })
public static org.jooq.RowCountQuery setLocal(@Stringly.Name String name, Param<?> value) {
return dsl().setLocal(name, value);
}
/**
* The <code>SET LOCAL</code> statement.
* <p>

View File

@ -3851,11 +3851,21 @@ public class DefaultDSLContext extends AbstractScope implements DSLContext, Seri
return new RevokeImpl(configuration(), new QueryPartList<>(privileges), true);
}
@Override
public org.jooq.RowCountQuery set(@Stringly.Name String name, Param<?> value) {
return new SetCommand(configuration(), DSL.name(name), value, false);
}
@Override
public org.jooq.RowCountQuery set(Name name, Param<?> value) {
return new SetCommand(configuration(), name, value, false);
}
@Override
public org.jooq.RowCountQuery setLocal(@Stringly.Name String name, Param<?> value) {
return new SetCommand(configuration(), DSL.name(name), value, true);
}
@Override
public org.jooq.RowCountQuery setLocal(Name name, Param<?> value) {
return new SetCommand(configuration(), name, value, true);