pub fn add_request_fees_timeout(wallet_handle: IndyHandle,
                                    submitter_did: &str,
                                    req_json: &str,
                                    inputs_json: &str,
                                    outputs_json: &str,
                                    extra: Option<&str>,
                                    timeout: Duration) -> Result<(String, String), ErrorCode> {
        let (receiver, command_handle, cb) = ClosureHandler::cb_ec_string_string();

        let err = Payment::_add_request_fees(command_handle, wallet_handle, submitter_did, req_json, inputs_json, outputs_json, extra, cb);

        ResultHandler::two_timeout(err, receiver, timeout)
    }
/// Modifies Indy request by adding information how to pay fees for this transaction
/// according to selected payment method.
///
/// Payment selection is performed by looking to o
///
/// This method consumes set of UTXO inputs and outputs. The difference between inputs balance
/// and outputs balance is the fee for this transaction.
///
/// Not that this method also produces correct fee signatures.
///
/// Format of inputs is specific for payment method. Usually it should reference payment transaction
/// with at least one output that corresponds to payment address that user owns.
///
/// # Arguments
/// * `wallet_handle` - wallet handle
/// * `submitter_did` - DID of request sender
/// * `req_json` - initial transaction request as json
/// * `inputs_json` - the list of UTXO inputs as json array
/// * `timeout` - the maximum time this function waits for a response
///
/// # Examples
/// inputs_json:
///   ["input1", ...]
///   Notes:
///     - each input should reference paymentAddress
///     - this param will be used to determine payment_method
/// outputs_json: The list of UTXO outputs as json array:
///   [{
///     paymentAddress: <str>, // payment address used as output
///     amount: <int>, // amount of tokens to transfer to this payment address
///     extra: <str>, // optional data
///   }]
///
/// # Returns
/// * `req_with_fees_json` - modified Indy request with added fees info
/// * `payment_method`
Modifies Indy request by adding information how to pay fees for this transaction
according to selected payment method.

Payment selection is performed by looking to o

This method consumes set of UTXO inputs and outputs. The difference between inputs balance
and outputs balance is the fee for this transaction.

Not that this method also produces correct fee signatures.

Format of inputs is specific for payment method. Usually it should reference payment transaction
with at least one output that corresponds to payment address that user owns.
Modifies Indy request by adding information how to pay fees for this transaction according to selected payment method . Payment selection is performed by looking to o This method consumes set of UTXO inputs and outputs . The difference between inputs balance and outputs balance is the fee for this transaction . Not that this method also produces correct fee signatures . Format of inputs is specific for payment method . Usually it should reference payment transaction with at least one output that corresponds to payment address that user owns .
pub fn add_request_fees_timeout(wallet_handle: IndyHandle,
                                    submitter_did: &str,
                                    req_json: &str,
                                    inputs_json: &str,
                                    outputs_json: &str,
                                    extra: Option<&str>,
                                    timeout: Duration) -> Result<(String, String), ErrorCode> {
        let (receiver, command_handle, cb) = ClosureHandler::cb_ec_string_string();
        let err = Payment::_add_request_fees(command_handle, wallet_handle, submitter_did, req_json, inputs_json, outputs_json, extra, cb);
        ResultHandler::two_timeout(err, receiver, timeout)
    }
pub fn add_request_fees_timeout ( wallet_handle : IndyHandle , submitter_did : & str , req_json : & str , inputs_json : & str , outputs_json : & str , extra : Option < & str > , timeout : Duration ) -> Result < ( String , String ) , ErrorCode > { let ( receiver , command_handle , cb ) = ClosureHandler :: cb_ec_string_string ( ) ; let err = Payment :: _add_request_fees ( command_handle , wallet_handle , submitter_did , req_json , inputs_json , outputs_json , extra , cb ) ; ResultHandler :: two_timeout ( err , receiver , timeout ) }
Modifies Indy request by adding information how to pay fees for this transaction
according to selected payment method.
Modifies Indy request by adding information how to pay fees for this transaction according to selected payment method .
`req_with_fees_json` - modified Indy request with added fees info
`payment_method`
` req_with_fees_json ` - modified Indy request with added fees info ` payment_method `
wallet_handle
IndyHandle
submitter_did
&str
req_json
&str
inputs_json
&str
outputs_json
&str
extra
Option<&str>
timeout
Duration
examples
["input1", ...]
Notes:
each input should reference paymentAddress
this param will be used to determine payment_method
outputs_json: The list of UTXO outputs as json array:
[{
paymentAddress: , // payment address used as output
amount: , // amount of tokens to transfer to this payment address
extra: , // optional data
}]
[ " input1 " ... ] Notes : each input should reference paymentAddress this param will be used to determine payment_method outputs_json : The list of UTXO outputs as json array : [ { paymentAddress : // payment address used as output amount : // amount of tokens to transfer to this payment address extra : // optional data } ]