base/lib/stellar/operation.rb
#
# Construct a new Stellar::Operation from the provided
# source account and body
#
# @param source_account [KeyPair, nil] the source account for the operation
# @param [(Symbol, XDR::Struct)] body a tuple containing operation type and operation object
#
# @return [Stellar::Operation] the built operation
Construct a new Stellar::Operation from the provided
source account and body
Construct a new Stellar :: Operation from the provided source account and body
def make(body:, source_account: nil)
        raise ArgumentError, "Bad :source_account" if source_account && !source_account.is_a?(Stellar::KeyPair)
        body = Stellar::Operation::Body.new(*body)
        Stellar::Operation.new(
          source_account: source_account&.muxed_account,
          body: body
        )
      end
def make ( body : , source_account : nil ) raise ArgumentError , "Bad :source_account" if source_account && ! source_account . is_a? ( Stellar :: KeyPair ) body = Stellar :: Operation :: Body . new ( * body ) Stellar :: Operation . new ( source_account : source_account &. muxed_account , body : body ) end
Construct a new Stellar::Operation from the provided
source account and body
Construct a new Stellar :: Operation from the provided source account and body
the built operation
the built operation
Stellar::Operation
body
source_account
the source account for the operation
the source account for the operation
body a tuple containing operation type and operation object
body a tuple containing operation type and operation object