Class List Method List File List

# Class: VertxWebApiContract::RequestParameters

Inherits:
  Object
  - Object
  - VertxWebApiContract::RequestParameters
  show all
Defined in:
  /Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web-api-contract/request_parameters.rb

## Overview

Container for request parameters

## Constant Summary

@@j_api_type =

      Object.new

## Class Method Summary (collapse)

- + (Boolean) accept?(obj)
- + (Object) j_api_type
- + (Object) j_class
- + (Object) unwrap(obj)
- + (Object) wrap(obj)

## Instance Method Summary (collapse)

- - (::VertxWebApiContract::RequestParameter) body
  Return request body.
- - (::VertxWebApiContract::RequestParameter) cookie_parameter(name = nil)
  Get cookie parameter by name.
- - (Array<String>) cookie_parameters_names
  Get list of all parameter names inside cookie.
- - (::VertxWebApiContract::RequestParameter) form_parameter(name = nil)
  Get form parameter by name.
- - (Array<String>) form_parameters_names
  Get list of all parameter names inside body form.
- - (::VertxWebApiContract::RequestParameter) header_parameter(name = nil)
  Get header parameter by name.
- - (Array<String>) header_parameters_names
  Get list of all parameter names inside header.
- - (::VertxWebApiContract::RequestParameter) path_parameter(name = nil)
  Get path parameter by name.
- - (Array<String>) path_parameters_names
  Get list of all parameter names inside path.
- - (::VertxWebApiContract::RequestParameter) query_parameter(name = nil)
  Get query parameter by name.
- - (Array<String>) query_parameters_names
  Get list of all parameter names inside query.

## Class Method Details

### + (`Boolean`) accept?(obj)

Returns:

- (`Boolean`)

    18
    19
    20
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web-api-contract/request_parameters.rb', line 18

    def @@j_api_type.accept?(obj)
      obj.class == RequestParameters
    end

### + (`Object`) j_api_type

    27
    28
    29
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web-api-contract/request_parameters.rb', line 27

    def self.j_api_type
      @@j_api_type
    end

### + (`Object`) j_class

    30
    31
    32
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web-api-contract/request_parameters.rb', line 30

    def self.j_class
      Java::IoVertxExtWebApi::RequestParameters.java_class
    end

### + (`Object`) unwrap(obj)

    24
    25
    26
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web-api-contract/request_parameters.rb', line 24

    def @@j_api_type.unwrap(obj)
      obj.j_del
    end

### + (`Object`) wrap(obj)

    21
    22
    23
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web-api-contract/request_parameters.rb', line 21

    def @@j_api_type.wrap(obj)
      RequestParameters.new(obj)
    end

## Instance Method Details

### - (`::VertxWebApiContract::RequestParameter`) body

Return request body

Returns:

- (`::VertxWebApiContract::RequestParameter`)

Raises:

- (`ArgumentError`)

    120
    121
    122
    123
    124
    125
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web-api-contract/request_parameters.rb', line 120

    def body
      if !block_given?
        return ::Vertx::Util::Utils.safe_create(@j_del.java_method(:body, []).call(),::VertxWebApiContract::RequestParameter)
      end
      raise ArgumentError, "Invalid arguments when calling body()"
    end

### - (`::VertxWebApiContract::RequestParameter`) cookie_parameter(name = nil)

Get cookie parameter by name

Parameters:

- name (`String`) (defaults to: `nil`) —
  Parameter name

Returns:

- (`::VertxWebApiContract::RequestParameter`)

Raises:

- (`ArgumentError`)

    95
    96
    97
    98
    99
    100
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web-api-contract/request_parameters.rb', line 95

    def cookie_parameter(name=nil)
      if name.class == String && !block_given?
        return ::Vertx::Util::Utils.safe_create(@j_del.java_method(:cookieParameter, [Java::java.lang.String.java_class]).call(name),::VertxWebApiContract::RequestParameter)
      end
      raise ArgumentError, "Invalid arguments when calling cookie_parameter(#{name})"
    end

### - (`Array<String>`) cookie_parameters_names

Get list of all parameter names inside cookie

Returns:

- (`Array<String>`)

Raises:

- (`ArgumentError`)

    86
    87
    88
    89
    90
    91
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web-api-contract/request_parameters.rb', line 86

    def cookie_parameters_names
      if !block_given?
        return @j_del.java_method(:cookieParametersNames, []).call().to_a.map { |elt| elt }
      end
      raise ArgumentError, "Invalid arguments when calling cookie_parameters_names()"
    end

### - (`::VertxWebApiContract::RequestParameter`) form_parameter(name = nil)

Get form parameter by name

Parameters:

- name (`String`) (defaults to: `nil`) —
  Parameter name

Returns:

- (`::VertxWebApiContract::RequestParameter`)

Raises:

- (`ArgumentError`)

    112
    113
    114
    115
    116
    117
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web-api-contract/request_parameters.rb', line 112

    def form_parameter(name=nil)
      if name.class == String && !block_given?
        return ::Vertx::Util::Utils.safe_create(@j_del.java_method(:formParameter, [Java::java.lang.String.java_class]).call(name),::VertxWebApiContract::RequestParameter)
      end
      raise ArgumentError, "Invalid arguments when calling form_parameter(#{name})"
    end

### - (`Array<String>`) form_parameters_names

Get list of all parameter names inside body form

Returns:

- (`Array<String>`)

Raises:

- (`ArgumentError`)

    103
    104
    105
    106
    107
    108
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web-api-contract/request_parameters.rb', line 103

    def form_parameters_names
      if !block_given?
        return @j_del.java_method(:formParametersNames, []).call().to_a.map { |elt| elt }
      end
      raise ArgumentError, "Invalid arguments when calling form_parameters_names()"
    end

### - (`::VertxWebApiContract::RequestParameter`) header_parameter(name = nil)

Get header parameter by name

Parameters:

- name (`String`) (defaults to: `nil`) —
  Parameter name

Returns:

- (`::VertxWebApiContract::RequestParameter`)

Raises:

- (`ArgumentError`)

    78
    79
    80
    81
    82
    83
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web-api-contract/request_parameters.rb', line 78

    def header_parameter(name=nil)
      if name.class == String && !block_given?
        return ::Vertx::Util::Utils.safe_create(@j_del.java_method(:headerParameter, [Java::java.lang.String.java_class]).call(name),::VertxWebApiContract::RequestParameter)
      end
      raise ArgumentError, "Invalid arguments when calling header_parameter(#{name})"
    end

### - (`Array<String>`) header_parameters_names

Get list of all parameter names inside header

Returns:

- (`Array<String>`)

Raises:

- (`ArgumentError`)

    69
    70
    71
    72
    73
    74
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web-api-contract/request_parameters.rb', line 69

    def header_parameters_names
      if !block_given?
        return @j_del.java_method(:headerParametersNames, []).call().to_a.map { |elt| elt }
      end
      raise ArgumentError, "Invalid arguments when calling header_parameters_names()"
    end

### - (`::VertxWebApiContract::RequestParameter`) path_parameter(name = nil)

Get path parameter by name

Parameters:

- name (`String`) (defaults to: `nil`) —
  Parameter name

Returns:

- (`::VertxWebApiContract::RequestParameter`)

Raises:

- (`ArgumentError`)

    44
    45
    46
    47
    48
    49
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web-api-contract/request_parameters.rb', line 44

    def path_parameter(name=nil)
      if name.class == String && !block_given?
        return ::Vertx::Util::Utils.safe_create(@j_del.java_method(:pathParameter, [Java::java.lang.String.java_class]).call(name),::VertxWebApiContract::RequestParameter)
      end
      raise ArgumentError, "Invalid arguments when calling path_parameter(#{name})"
    end

### - (`Array<String>`) path_parameters_names

Get list of all parameter names inside path

Returns:

- (`Array<String>`)

Raises:

- (`ArgumentError`)

    35
    36
    37
    38
    39
    40
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web-api-contract/request_parameters.rb', line 35

    def path_parameters_names
      if !block_given?
        return @j_del.java_method(:pathParametersNames, []).call().to_a.map { |elt| elt }
      end
      raise ArgumentError, "Invalid arguments when calling path_parameters_names()"
    end

### - (`::VertxWebApiContract::RequestParameter`) query_parameter(name = nil)

Get query parameter by name

Parameters:

- name (`String`) (defaults to: `nil`) —
  Parameter name

Returns:

- (`::VertxWebApiContract::RequestParameter`)

Raises:

- (`ArgumentError`)

    61
    62
    63
    64
    65
    66
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web-api-contract/request_parameters.rb', line 61

    def query_parameter(name=nil)
      if name.class == String && !block_given?
        return ::Vertx::Util::Utils.safe_create(@j_del.java_method(:queryParameter, [Java::java.lang.String.java_class]).call(name),::VertxWebApiContract::RequestParameter)
      end
      raise ArgumentError, "Invalid arguments when calling query_parameter(#{name})"
    end

### - (`Array<String>`) query_parameters_names

Get list of all parameter names inside query

Returns:

- (`Array<String>`)

Raises:

- (`ArgumentError`)

    52
    53
    54
    55
    56
    57
    # File '/Users/julien/java/vertx-stack/stack-docs/target/rb/vertx-web-api-contract/request_parameters.rb', line 52

    def query_parameters_names
      if !block_given?
        return @j_del.java_method(:queryParametersNames, []).call().to_a.map { |elt| elt }
      end
      raise ArgumentError, "Invalid arguments when calling query_parameters_names()"
    end