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.

Author:
Julien Viet
See Also:
  • PreparedQuery
  • Field Details

  • Constructor Details

    • PreparedQuery

      public PreparedQuery(io.vertx.sqlclient.PreparedQuery<T> delegate)
      Create a new instance of PreparedQuery delegating to the given (non-null) instance of PreparedQuery.
    • PreparedQuery

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

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

    • getDelegate

      public io.vertx.sqlclient.PreparedQuery<T> getDelegate()
      Get the delegate instance.

      This method returns the instance on which this shim is delegating the calls. And so, give you access to the bare API.

      Specified by:
      getDelegate in interface MutinyDelegate
      Overrides:
      getDelegate in class Query<T>
      Returns:
      the delegate instance
    • 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. The uni emits the result of the operation as item. If the operation fails, the uni emits the failure.

      Don't forget to subscribe on it to trigger the operation.

      Returns:
      A Uni representing the asynchronous result of this operation.
      See Also:
      • io.vertx.sqlclient.PreparedQuery#execute(Tuple)
    • executeAndAwait

      public T executeAndAwait(Tuple tuple)
      Execute the query.

      Unlike the bare Vert.x variant, this method returns a PreparedQuery. This method awaits indefinitely 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).

      Returns:
      The operation result
      See Also:
      • io.vertx.sqlclient.PreparedQuery#execute(Tuple)
    • executeAndForget

      public PreparedQuery<T> executeAndForget(Tuple tuple)
      Execute the query.

      Unlike the bare Vert.x variant, this method ignores the PreparedQuery result or any failure.

      Returns:
      The current instance to chain operations if needed.
      See Also:
      • io.vertx.sqlclient.PreparedQuery#execute(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. The uni emits the result of the operation as item. If the operation fails, the uni emits the failure.

      Don't forget to subscribe on it to trigger the operation.

      Parameters:
      batch - the batch of tuples
      Returns:
      A Uni representing the asynchronous result of this operation.
      See Also:
      • PreparedQuery.executeBatch(List)
    • executeBatchAndAwait

      public T executeBatchAndAwait(List<Tuple> batch)
      Execute the query with a batch of tuples.

      Unlike the bare Vert.x variant, this method returns a PreparedQuery. This method awaits indefinitely 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 operation result
      See Also:
      • PreparedQuery.executeBatch(List)
    • executeBatchAndForget

      public PreparedQuery<T> executeBatchAndForget(List<Tuple> batch)
      Execute the query with a batch of tuples.

      Unlike the bare Vert.x variant, this method ignores the PreparedQuery result or any failure.

      Parameters:
      batch - the batch of tuples
      Returns:
      The current instance to chain operations if needed.
      See Also:
      • PreparedQuery.executeBatch(List)
    • execute

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

      Unlike the bare Vert.x variant, this method returns a Uni. The uni emits the result of the operation as item. If the operation fails, the uni emits the failure.

      Don't forget to subscribe on it to trigger the operation.

      Overrides:
      execute in class Query<T>
      Returns:
      A Uni representing the asynchronous result of this operation.
      See Also:
      • Query.execute()
    • executeAndAwait

      public T executeAndAwait()
      Execute the query.

      Unlike the bare Vert.x variant, this method returns a PreparedQuery. This method awaits indefinitely 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 operation result
      See Also:
      • Query.execute()
    • executeAndForget

      public PreparedQuery<T> executeAndForget()
      Execute the query.

      Unlike the bare Vert.x variant, this method ignores the PreparedQuery result or any failure.

      Overrides:
      executeAndForget in class Query<T>
      Returns:
      The current instance to chain operations if needed.
      See Also:
      • Query.execute()
    • mapping

      public <U> PreparedQuery<RowSet<U>> mapping(Function<Row,U> mapper)
      Use the specified mapper for mapping Row to <U>.
      Overrides:
      mapping in class Query<T>
    • newInstance

      public static <T> PreparedQuery<T> newInstance(io.vertx.sqlclient.PreparedQuery<T> delegate)
      Creates a new instance of the PreparedQuery.
    • newInstance

      public static <T> PreparedQuery<T> newInstance(io.vertx.sqlclient.PreparedQuery<T> delegate, TypeArg<T> typeArg_0)
      Creates a new instance of the PreparedQuery.
    • hashCode

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

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

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