Class: Minter::SignedTx

Inherits:
Object
  • Object
show all
Defined in:
lib/minter/transactions/signed_tx.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(tx_hash: nil, transaction: nil) ⇒ SignedTx

Returns a new instance of SignedTx.



7
8
9
10
# File 'lib/minter/transactions/signed_tx.rb', line 7

def initialize(tx_hash: nil, transaction: nil)
  @tx_hash = tx_hash
  @transaction = transaction
end

Instance Attribute Details

#transactionObject (readonly)

Returns the value of attribute transaction.



5
6
7
# File 'lib/minter/transactions/signed_tx.rb', line 5

def transaction
  @transaction
end

#tx_hashObject (readonly)

Returns the value of attribute tx_hash.



5
6
7
# File 'lib/minter/transactions/signed_tx.rb', line 5

def tx_hash
  @tx_hash
end

Instance Method Details

#sendObject



12
13
14
# File 'lib/minter/transactions/signed_tx.rb', line 12

def send
  Minter::Api::Client.new.send_transaction(transaction: tx_hash)
end