io.vertx.redis.client

## Interface Request

-     public interface Request

  Builder for REDIS requests that will be encoded according to the RESP protocol was introduced in Redis 1.2. Which became the standard way for talking with the Redis server in Redis 2.0. Redis protocol documentation states:

  > Clients send commands to a Redis server as a RESP Array of Bulk Strings.

  So all non String/Bulk types will be encoded to Bulk for convenience.
  Author:
    Paulo Lopes

- - ### Method Summary

    All Methods Static Methods Instance Methods Abstract Methods Default Methods Deprecated Methods
    Modifier and Type | Method and Description
    --- | ---
    `Request` | `arg(boolean arg)` Adds a boolean encoded to string
    `Request` | `arg(Buffer arg)` Adds a String key argument
    `default Request` | `arg(byte arg)` Adds a byte encoded to string
    `Request` | `arg(byte[] arg)` Adds a byte array
    `default Request` | `arg(double arg)` Adds a double encoded to string
    `default Request` | `arg(float arg)` Adds a float encoded to string
    `default Request` | `arg(int arg)` Adds a int encoded to string
    `default Request` | `arg(JsonArray arg)` Adds a JsonArray argument, the encoding will serialize the json as value0, value1, ...
    `default Request` | `arg(JsonObject arg)` Adds a JsonObject argument, the encoding will serialize the json as key0, value0, key1, value1, ...
    `Request` | `arg(long arg)` Adds a long encoded to string
    `default Request` | `arg(short arg)` Adds a short encoded to string
    `default Request` | `arg(String arg)` Adds a String argument using UTF8 character encoding
    `default Request` | `arg(String arg, String enc)` Adds a String using a specific character encoding argument
    `static Request` | `cmd(Command command)`
    `Command` | `command()` Get the Command that is to be used by this request.
    `Request` | `nullArg()` Deprecated. REDIS does not support `null` as a parameter, only as response. This was a deviation from the official protocol which should be avoided. Other clients explicitly do not allow this. Adds a `null` encoded string. Redis does not allow storing the `null` value by itself. This method will encode any null value as the four character long string `"null"`. As a recommendation, this method should not be used directly unless this is the intented behavior. It is present to handle special cases such as encoding of `JsonObject` and `JsonArray` which may contain null values.

- - ### Method Detail

    - #### cmd

          static Request cmd(Command command)

    - #### arg

          Request arg(byte[] arg)

      Adds a byte array
      Returns:
        self

    - #### arg

          default Request arg(String arg)

      Adds a String argument using UTF8 character encoding
      Returns:
        self

    - #### arg

          default Request arg(String arg,
                              String enc)

      Adds a String using a specific character encoding argument
      Returns:
        self

    - #### arg

          Request arg(Buffer arg)

      Adds a String key argument
      Returns:
        self

    - #### arg

          Request arg(long arg)

      Adds a long encoded to string
      Returns:
        self

    - #### arg

          default Request arg(int arg)

      Adds a int encoded to string
      Returns:
        self

    - #### arg

          default Request arg(short arg)

      Adds a short encoded to string
      Returns:
        self

    - #### arg

          default Request arg(byte arg)

      Adds a byte encoded to string
      Returns:
        self

    - #### arg

          default Request arg(float arg)

      Adds a float encoded to string
      Returns:
        self

    - #### arg

          default Request arg(double arg)

      Adds a double encoded to string
      Returns:
        self

    - #### arg

          Request arg(boolean arg)

      Adds a boolean encoded to string
      Returns:
        self

    - #### arg

          default Request arg(JsonObject arg)

      Adds a JsonObject argument, the encoding will serialize the json as key0, value0, key1, value1, ... keyN, valueN. This is a non-optimized serialization and will just use the string encoding of the values for non buffers. All `null` values will follow the encoding rules of `nullArg()`.
      Returns:
        self
      Throws:
        `IllegalArgumentException` - when values are of type JsonArray or JsonObject

    - #### arg

          default Request arg(JsonArray arg)

      Adds a JsonArray argument, the encoding will serialize the json as value0, value1, ... valueN. This is a non-optimized serialization and will just use the string encoding of the values for non buffers. All `null` values will follow the encoding rules of `nullArg()`.
      Returns:
        self
      Throws:
        `IllegalArgumentException` - when values are of type JsonArray or JsonObject

    - #### nullArg

          @Deprecated
          Request nullArg()

      Deprecated. REDIS does not support `null` as a parameter, only as response. This was a deviation from the official protocol which should be avoided. Other clients explicitly do not allow this. Adds a `null` encoded string. Redis does not allow storing the `null` value by itself. This method will encode any null value as the four character long string `"null"`. As a recommendation, this method should not be used directly unless this is the intented behavior. It is present to handle special cases such as encoding of `JsonObject` and `JsonArray` which may contain null values.
      Returns:
        self

    - #### command

          Command command()

      Get the Command that is to be used by this request.
      Returns:
        the command.

Copyright © 2021 Eclipse. All rights reserved.