Class PreparedQuery<T>

java.lang.Object
io.vertx.mutiny.sqlclient.Query<T>
io.vertx.mutiny.sqlclient.PreparedQuery<T>
All Implemented Interfaces:
MutinyDelegate

public class PreparedQuery<T> extends Query<T> implements MutinyDelegate
A query for a prepared statement allowing parameterized execution of the query, this query will use a prepared statement.

NOTE: This class has been automatically generated from the original non Mutiny-ified interface using Vert.x codegen.

  • Field Details

  • Constructor Details

    • PreparedQuery

      public PreparedQuery(io.vertx.sqlclient.PreparedQuery delegate)
    • PreparedQuery

      public PreparedQuery(Object delegate, TypeArg<T> typeArg_0)
    • PreparedQuery

      public PreparedQuery(io.vertx.sqlclient.PreparedQuery delegate, TypeArg<T> typeArg_0)
  • Method Details

    • getDelegate

      public io.vertx.sqlclient.PreparedQuery getDelegate()
      Specified by:
      getDelegate in interface MutinyDelegate
      Overrides:
      getDelegate in class Query<T>
      Returns:
      the delegate used by this Mutiny object of generated type
    • toString

      public String toString()
      Overrides:
      toString in class Query<T>
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Query<T>
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Query<T>
    • execute

      @CheckReturnValue public io.smallrye.mutiny.Uni<T> execute()
      Execute the query.

      Unlike the bare Vert.x variant, this method returns a Uni. Don't forget to subscribe on it to trigger the operation.

      Overrides:
      execute in class Query<T>
      Returns:
      the uni firing the result of the operation when completed, or a failure if the operation failed.
    • executeAndAwait

      public T executeAndAwait()
      Blocking variant of Query.execute().

      This method waits for the completion of the underlying asynchronous operation. If the operation completes successfully, the result is returned, otherwise the failure is thrown (potentially wrapped in a RuntimeException).

      Overrides:
      executeAndAwait in class Query<T>
      Returns:
      the T instance produced by the operation.
    • executeAndForget

      public void executeAndForget()
      Variant of Query.execute() that ignores the result of the operation.

      This method subscribes on the result of Query.execute(), but discards the outcome (item or failure). This method is useful to trigger the asynchronous operation from Query.execute() but you don't need to compose it with other operations.

      Overrides:
      executeAndForget in class Query<T>
    • execute

      @CheckReturnValue public io.smallrye.mutiny.Uni<T> execute(Tuple tuple)
      Execute the query.

      Unlike the bare Vert.x variant, this method returns a Uni. Don't forget to subscribe on it to trigger the operation.

      Parameters:
      tuple -
      Returns:
      the uni firing the result of the operation when completed, or a failure if the operation failed.
    • executeAndAwait

      public T executeAndAwait(Tuple tuple)
      Blocking variant of execute(io.vertx.mutiny.sqlclient.Tuple).

      This method waits for the completion of the underlying asynchronous operation. If the operation completes successfully, the result is returned, otherwise the failure is thrown (potentially wrapped in a RuntimeException).

      Parameters:
      tuple -
      Returns:
      the T instance produced by the operation.
    • executeAndForget

      public void executeAndForget(Tuple tuple)
      Variant of execute(io.vertx.mutiny.sqlclient.Tuple) that ignores the result of the operation.

      This method subscribes on the result of execute(io.vertx.mutiny.sqlclient.Tuple), but discards the outcome (item or failure). This method is useful to trigger the asynchronous operation from execute(io.vertx.mutiny.sqlclient.Tuple) but you don't need to compose it with other operations.

      Parameters:
      tuple -
    • executeBatch

      @CheckReturnValue public io.smallrye.mutiny.Uni<T> executeBatch(List<Tuple> batch)
      Execute the query with a batch of tuples.

      Unlike the bare Vert.x variant, this method returns a Uni. Don't forget to subscribe on it to trigger the operation.

      Parameters:
      batch - the batch of tuples
      Returns:
      the uni firing the result of the operation when completed, or a failure if the operation failed.
    • executeBatchAndAwait

      public T executeBatchAndAwait(List<Tuple> batch)
      Blocking variant of executeBatch(List).

      This method waits for the completion of the underlying asynchronous operation. If the operation completes successfully, the result is returned, otherwise the failure is thrown (potentially wrapped in a RuntimeException).

      Parameters:
      batch - the batch of tuples
      Returns:
      the T instance produced by the operation.
    • executeBatchAndForget

      public void executeBatchAndForget(List<Tuple> batch)
      Variant of executeBatch(List) that ignores the result of the operation.

      This method subscribes on the result of executeBatch(List), but discards the outcome (item or failure). This method is useful to trigger the asynchronous operation from executeBatch(List) but you don't need to compose it with other operations.

      Parameters:
      batch - the batch of tuples
    • mapping

      public <U> PreparedQuery<RowSet<U>> mapping(Function<Row,U> mapper)
      Overrides:
      mapping in class Query<T>
      Parameters:
      mapper -
      Returns:
    • newInstance

      public static <T> PreparedQuery<T> newInstance(io.vertx.sqlclient.PreparedQuery arg)
    • newInstance

      public static <T> PreparedQuery<T> newInstance(io.vertx.sqlclient.PreparedQuery arg, TypeArg<T> __typeArg_T)