Class: Coinsetter::Order

Inherits:
Model
  • Object
show all
Defined in:
lib/coinsetter/order.rb

Instance Attribute Summary collapse

Attributes inherited from Model

#error, #message

Instance Method Summary collapse

Methods inherited from Model

#attributes, #attributes=, #initialize

Constructor Details

This class inherits a constructor from Coinsetter::Model

Instance Attribute Details

#account_uuidObject

Returns the value of attribute account_uuid.



3
4
5
# File 'lib/coinsetter/order.rb', line 3

def 
  @account_uuid
end

#cost_basisObject

Returns the value of attribute cost_basis.



3
4
5
# File 'lib/coinsetter/order.rb', line 3

def cost_basis
  @cost_basis
end

#create_dateObject

Returns the value of attribute create_date.



5
6
7
# File 'lib/coinsetter/order.rb', line 5

def create_date
  @create_date
end

#customer_uuidObject

Returns the value of attribute customer_uuid.



3
4
5
# File 'lib/coinsetter/order.rb', line 3

def customer_uuid
  @customer_uuid
end

#filled_quantityObject

Returns the value of attribute filled_quantity.



3
4
5
# File 'lib/coinsetter/order.rb', line 3

def filled_quantity
  @filled_quantity
end

#open_quantityObject

Returns the value of attribute open_quantity.



3
4
5
# File 'lib/coinsetter/order.rb', line 3

def open_quantity
  @open_quantity
end

#order_numberObject

Returns the value of attribute order_number.



4
5
6
# File 'lib/coinsetter/order.rb', line 4

def order_number
  @order_number
end

#order_ypeObject

Returns the value of attribute order_ype.



4
5
6
# File 'lib/coinsetter/order.rb', line 4

def order_ype
  @order_ype
end

#requested_priceObject

Returns the value of attribute requested_price.



4
5
6
# File 'lib/coinsetter/order.rb', line 4

def requested_price
  @requested_price
end

#requested_uantityObject

Returns the value of attribute requested_uantity.



4
5
6
# File 'lib/coinsetter/order.rb', line 4

def requested_uantity
  @requested_uantity
end

#routing_methodObject

Returns the value of attribute routing_method.



5
6
7
# File 'lib/coinsetter/order.rb', line 5

def routing_method
  @routing_method
end

#sideObject

Returns the value of attribute side.



4
5
6
# File 'lib/coinsetter/order.rb', line 4

def side
  @side
end

#stageObject

Returns the value of attribute stage.



4
5
6
# File 'lib/coinsetter/order.rb', line 4

def stage
  @stage
end

#symbolObject

Returns the value of attribute symbol.



5
6
7
# File 'lib/coinsetter/order.rb', line 5

def symbol
  @symbol
end

#uuidObject

Returns the value of attribute uuid.



3
4
5
# File 'lib/coinsetter/order.rb', line 3

def uuid
  @uuid
end

Instance Method Details

#destroy!(client_session_uuid) ⇒ Object



7
8
9
10
# File 'lib/coinsetter/order.rb', line 7

def destroy!(client_session_uuid)
  call = Coinsetter::Net.delete(path, {"coinsetter-client-session-id" => client_session_uuid})
  parse call
end

#parse(string) ⇒ Object



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

def parse(string)
  Coinsetter::Helper.parse_message! string
end

#pathObject



12
13
14
# File 'lib/coinsetter/order.rb', line 12

def path
  "order/#{uuid}"
end