Class: Etna::Clients::Metis::FindRequest

Inherits:
Struct
  • Object
show all
Includes:
JsonSerializableStruct
Defined in:
lib/etna/clients/metis/models.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from JsonSerializableStruct

#as_json, included, #to_json

Constructor Details

#initialize(**args) ⇒ FindRequest



100
101
102
# File 'lib/etna/clients/metis/models.rb', line 100

def initialize(**args)
  super({params: []}.update(args))
end

Instance Attribute Details

#bucket_nameObject

Returns the value of attribute bucket_name



97
98
99
# File 'lib/etna/clients/metis/models.rb', line 97

def bucket_name
  @bucket_name
end

#limitObject

Returns the value of attribute limit



97
98
99
# File 'lib/etna/clients/metis/models.rb', line 97

def limit
  @limit
end

#offsetObject

Returns the value of attribute offset



97
98
99
# File 'lib/etna/clients/metis/models.rb', line 97

def offset
  @offset
end

#paramsObject

Returns the value of attribute params



97
98
99
# File 'lib/etna/clients/metis/models.rb', line 97

def params
  @params
end

#project_nameObject

Returns the value of attribute project_name



97
98
99
# File 'lib/etna/clients/metis/models.rb', line 97

def project_name
  @project_name
end

Instance Method Details

#add_param(param) ⇒ Object



104
105
106
# File 'lib/etna/clients/metis/models.rb', line 104

def add_param(param)
  params << param
end

#to_hObject



108
109
110
111
112
# File 'lib/etna/clients/metis/models.rb', line 108

def to_h
  # The nested :params values don't get converted correctly with transform_values, so it's
  #   easier to do from a JSON string
  JSON.parse(to_json, :symbolize_names => true)
end