Class: Counterparty::Order

Inherits:
CounterResource show all
Defined in:
lib/counterparty/resources.rb

Overview

An object that describes a specific order.

Instance Attribute Summary collapse

Attributes inherited from CounterResource

#allow_unconfirmed_inputs, #encoding, #fee, #fee_per_kb, #pubkey, #result_attributes

Method Summary

Methods inherited from CounterResource

#==, api_name, bitcoin, find, #initialize, #save!, to_create_request, to_get_request, #to_raw_tx, #to_signed_tx

Constructor Details

This class inherits a constructor from Counterparty::CounterResource

Instance Attribute Details

#block_indexObject

(integer): The block index (block number in the block chain)



450
451
452
# File 'lib/counterparty/resources.rb', line 450

def block_index
  @block_index
end

#expirationObject

(integer): The number of blocks over which the order should be valid



478
479
480
# File 'lib/counterparty/resources.rb', line 478

def expiration
  @expiration
end

#fee_providedObject

(integer): The miners’ fee provided; in BTC; required only if selling BTC (should not be lower than is required for acceptance in a block)



482
483
484
# File 'lib/counterparty/resources.rb', line 482

def fee_provided
  @fee_provided
end

#fee_requiredObject

(integer): The miners’ fee required to be paid by orders for them to match this one; in BTC; required only if buying BTC (may be zero, though)



486
487
488
# File 'lib/counterparty/resources.rb', line 486

def fee_required
  @fee_required
end

#get_assetObject

(string): The asset desired in exchange



465
466
467
# File 'lib/counterparty/resources.rb', line 465

def get_asset
  @get_asset
end

#get_quantityObject

(integer): The quantity of the specified asset desired in exchange



468
469
470
# File 'lib/counterparty/resources.rb', line 468

def get_quantity
  @get_quantity
end

#get_remainingObject

(integer): The quantity of the specified get asset remaining for the order



471
472
473
# File 'lib/counterparty/resources.rb', line 471

def get_remaining
  @get_remaining
end

#give_assetObject

(string): The asset being offered



456
457
458
# File 'lib/counterparty/resources.rb', line 456

def give_asset
  @give_asset
end

#give_quantityObject

(integer): The quantity of the specified asset being offered



459
460
461
# File 'lib/counterparty/resources.rb', line 459

def give_quantity
  @give_quantity
end

#give_remainingObject

(integer): The quantity of the specified give asset remaining for the order



462
463
464
# File 'lib/counterparty/resources.rb', line 462

def give_remaining
  @give_remaining
end

#priceObject

(float): The given exchange rate (as an exchange ratio desired from the asset offered to the asset desired)



475
476
477
# File 'lib/counterparty/resources.rb', line 475

def price
  @price
end

#sourceObject

(string): The address that made the order



453
454
455
# File 'lib/counterparty/resources.rb', line 453

def source
  @source
end

#tx_hashObject

(string): The transaction hash



447
448
449
# File 'lib/counterparty/resources.rb', line 447

def tx_hash
  @tx_hash
end

#tx_indexObject

(integer): The transaction index



444
445
446
# File 'lib/counterparty/resources.rb', line 444

def tx_index
  @tx_index
end