Class: OandaAPI::Resource::Position

Inherits:
OandaAPI::ResourceBase show all
Defined in:
lib/oanda_api/resource/position.rb

Overview

Position value object. See the Oanda Developer Guide for information about Positions.

Constant Summary

Constants inherited from OandaAPI::ResourceBase

OandaAPI::ResourceBase::NOT_PLURALIZED

Instance Attribute Summary collapse

Attributes inherited from OandaAPI::ResourceBase

#location

Method Summary

Methods inherited from OandaAPI::ResourceBase

class_from_symbol, #initialize, labs_resource?, pluralize, #to_json

Constructor Details

This class inherits a constructor from OandaAPI::ResourceBase

Instance Attribute Details

#avg_priceObject Also known as: price

Returns the value of attribute avg_price.



6
7
8
# File 'lib/oanda_api/resource/position.rb', line 6

def avg_price
  @avg_price
end

#idsObject

Returns the value of attribute ids.



6
7
8
# File 'lib/oanda_api/resource/position.rb', line 6

def ids
  @ids
end

#instrumentObject

Returns the value of attribute instrument.



6
7
8
# File 'lib/oanda_api/resource/position.rb', line 6

def instrument
  @instrument
end

#sideObject

Returns the value of attribute side.



6
7
8
# File 'lib/oanda_api/resource/position.rb', line 6

def side
  @side
end

#total_unitsObject Also known as: units

Returns the value of attribute total_units.



6
7
8
# File 'lib/oanda_api/resource/position.rb', line 6

def total_units
  @total_units
end