Class: Scalarium::Resource

Inherits:
OpenStruct
  • Object
show all
Includes:
Api
Defined in:
lib/scalarium/resource.rb

Direct Known Subclasses

App, Cloud, Cloud::Instance, Cloud::Rol

Instance Method Summary collapse

Methods included from Api

#get, #post

Constructor Details

#initialize(token, attributes = {}) ⇒ Resource

Returns a new instance of Resource.



4
5
6
7
# File 'lib/scalarium/resource.rb', line 4

def initialize(token, attributes = {})
  @token = token
  super(attributes)
end

Instance Method Details

#idObject



9
10
11
# File 'lib/scalarium/resource.rb', line 9

def id
  @table[:id]
end