Module: Hyperdrive::Values

Defined in:
lib/hyperdrive/values.rb

Class Method Summary collapse

Class Method Details

.request_methodsObject



3
4
5
# File 'lib/hyperdrive/values.rb', line 3

def self.request_methods
  %w(GET HEAD OPTIONS POST PUT PATCH DELETE).freeze
end

.request_methods_string_mapObject



19
20
21
22
23
24
25
26
27
28
29
# File 'lib/hyperdrive/values.rb', line 19

def self.request_methods_string_map
  {
    'GET'     => :get,
    'HEAD'    => :head,
    'OPTIONS' => :options,
    'POST'    => :post,
    'PUT'     => :put,
    'PATCH'   => :patch,
    'DELETE'  => :delete
  }.freeze
end

.request_methods_symbol_mapObject



7
8
9
10
11
12
13
14
15
16
17
# File 'lib/hyperdrive/values.rb', line 7

def self.request_methods_symbol_map
  {
    get:     'GET',
    head:    'HEAD',
    options: 'OPTIONS',
    post:    'POST',
    put:     'PUT',
    patch:   'PATCH',
    delete:  'DELETE'
  }.freeze
end