Class: OsoCloud::Value

Inherits:
Struct
  • Object
show all
Defined in:
lib/oso/oso.rb

Overview

Represents an object in your application, with a type and id. Both “type” and “id” should be strings.

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#idObject

Returns the value of attribute id

Returns:

  • (Object)

    the current value of id



15
16
17
# File 'lib/oso/oso.rb', line 15

def id
  @id
end

#typeObject

Returns the value of attribute type

Returns:

  • (Object)

    the current value of type



15
16
17
# File 'lib/oso/oso.rb', line 15

def type
  @type
end

Instance Method Details

#to_api_valueObject



16
17
18
# File 'lib/oso/oso.rb', line 16

def to_api_value
  OsoCloud::Helpers.extract_value(self)
end