base/lib/stellar/operation.rb
def create_passive_sell_offer(selling:, buying:, amount:, price:, source_account: nil)
        selling = Asset.send(*selling) if selling.is_a?(Array)
        buying = Asset.send(*buying) if buying.is_a?(Array)

        op = CreatePassiveSellOfferOp.new(
          buying: buying,
          selling: selling,
          amount: interpret_amount(amount),
          price: Price.from(price)
        )

        make(source_account: source_account, body: [:create_passive_sell_offer, op])
      end
# Create Passive Sell Offer operation builder
#
# @param source_account [KeyPair, nil] the source account for the operation
# @param selling [Asset] the asset to sell
# @param buying [Asset] the asset to buy
# @param amount [String, Numeric] the amount of asset to sell
# @param price [String, Numeric, Price] the price of the selling asset in terms of buying asset
#
# @return [Operation] the built operation
Create Passive Sell Offer operation builder
Create Passive Sell Offer operation builder
def create_passive_sell_offer(selling:, buying:, amount:, price:, source_account: nil)
        selling = Asset.send(*selling) if selling.is_a?(Array)
        buying = Asset.send(*buying) if buying.is_a?(Array)
        op = CreatePassiveSellOfferOp.new(
          buying: buying,
          selling: selling,
          amount: interpret_amount(amount),
          price: Price.from(price)
        )
        make(source_account: source_account, body: [:create_passive_sell_offer, op])
      end
def create_passive_sell_offer ( selling : , buying : , amount : , price : , source_account : nil ) selling = Asset . send ( * selling ) if selling . is_a? ( Array ) buying = Asset . send ( * buying ) if buying . is_a? ( Array ) op = CreatePassiveSellOfferOp . new ( buying : buying , selling : selling , amount : interpret_amount ( amount ) , price : Price . from ( price ) ) make ( source_account : source_account , body : [ :create_passive_sell_offer , op ] ) end
Create Passive Sell Offer operation builder
Create Passive Sell Offer operation builder
the built operation
the built operation
Operation
selling
the asset to sell
the asset to sell
buying
the asset to buy
the asset to buy
amount
the amount of asset to sell
the amount of asset to sell
price
the price of the selling asset in terms of buying asset
the price of the selling asset in terms of buying asset
source_account
the source account for the operation
the source account for the operation