Class: Kloxo::API::Resource

Inherits:
Request
  • Object
show all
Defined in:
lib/kloxo/api/resource.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(params = {}) ⇒ Resource

Returns a new instance of Resource.



6
7
8
# File 'lib/kloxo/api/resource.rb', line 6

def initialize params = {}
  self.type = params[:type]
end

Instance Attribute Details

#typeObject

Returns the value of attribute type.



4
5
6
# File 'lib/kloxo/api/resource.rb', line 4

def type
  @type
end

Instance Method Details

#paramObject



10
11
12
13
14
15
# File 'lib/kloxo/api/resource.rb', line 10

def param
  {
    "action" => "simplelist",
    "resource" => self.type
  }.to_param
end