- java.lang.Object
-
- io.helidon.dbclient.common.DbStatementContext
-
public class DbStatementContext extends Object
Context of execution of a specific statement.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
DbStatementContext.Builder
A fluent API builder to createDbStatementContext
.static class
DbStatementContext.BuilderBase<T extends DbStatementContext.BuilderBase<T>>
A base builder that must be extended to implement a newDbStatementContext
.
-
Constructor Summary
Constructors Modifier Constructor Description protected
DbStatementContext(DbStatementContext.BuilderBase<?> builder)
Create a new instance using a builder each implementation must extend.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static DbStatementContext.Builder
builder()
Create a new builder.DbClientContext
clientContext()
Client context associated with the client executing this statement.static DbStatementContext
create(DbClientContext clientContext, DbStatementType statementType, String statementName, String statementText)
Create a new instance of this class.String
statement()
Statement text as configured.String
statementName()
Name of this statement.DbStatementType
statementType()
Statement type of this statement.
-
-
-
Constructor Detail
-
DbStatementContext
protected DbStatementContext(DbStatementContext.BuilderBase<?> builder)
Create a new instance using a builder each implementation must extend.- Parameters:
builder
- to get required fields from
-
-
Method Detail
-
builder
public static DbStatementContext.Builder builder()
Create a new builder.- Returns:
- a new builder instance
-
create
public static DbStatementContext create(DbClientContext clientContext, DbStatementType statementType, String statementName, String statementText)
Create a new instance of this class.- Parameters:
clientContext
- DB client contextstatementType
- type of statementstatementName
- name of statementstatementText
- text of the statement to execute- Returns:
- a new statement context
-
clientContext
public DbClientContext clientContext()
Client context associated with the client executing this statement.- Returns:
- client context
-
statementType
public DbStatementType statementType()
Statement type of this statement.- Returns:
- type of statement
-
statementName
public String statementName()
Name of this statement.- Returns:
- name of statement
-
statement
public String statement()
Statement text as configured.- Returns:
- statement text
-
-