public function _sendTx(Transaction $tx, array $signInfo, $apiCheckFee = true) {
        if ($this->locked) {
            throw new \Exception("Wallet needs to be unlocked to pay");
        }

        assert(Util::all(function ($signInfo) {
            return $signInfo instanceof SignInfo;
        }, $signInfo), '$signInfo should be SignInfo[]');

        // sign the transaction with our keys
        $signed = $this->signTransaction($tx, $signInfo);

        $txs = [
            'signed_transaction' => $signed->getHex(),
            'base_transaction' => $signed->getBaseSerialization()->getHex(),
        ];

        // send the transaction
        return $this->sendTransaction($txs, array_map(function (SignInfo $r) {
            return (string)$r->path;
        }, $signInfo), $apiCheckFee);
    }
public function _sendTx(Transaction $tx, array $signInfo, $apiCheckFee = true) {
        if ($this->locked) {
            throw new \Exception("Wallet needs to be unlocked to pay");
        }

        assert(Util::all(function ($signInfo) {
            return $signInfo instanceof SignInfo;
        }, $signInfo), '$signInfo should be SignInfo[]');

        // sign the transaction with our keys
        $signed = $this->signTransaction($tx, $signInfo);

        $txs = [
            'signed_transaction' => $signed->getHex(),
            'base_transaction' => $signed->getBaseSerialization()->getHex(),
        ];

        // send the transaction
        return $this->sendTransaction($txs, array_map(function (SignInfo $r) {
            return (string)$r->path;
        }, $signInfo), $apiCheckFee);
    }
public function _sendTx ( Transaction $ tx , array $ signInfo , $ apiCheckFee = true ) { if ( $ this -> locked ) { throw new \ Exception ( "Wallet needs to be unlocked to pay" ) ; } assert ( Util :: all ( function ( $ signInfo ) { return $ signInfo instanceof SignInfo ; } , $ signInfo ) , '$signInfo should be SignInfo[]' ) ; // sign the transaction with our keys $ signed = $ this -> signTransaction ( $ tx , $ signInfo ) ; $ txs = [ 'signed_transaction' => $ signed -> getHex ( ) , 'base_transaction' => $ signed -> getBaseSerialization ( ) -> getHex ( ) , ] ; // send the transaction return $ this -> sendTransaction ( $ txs , array_map ( function ( SignInfo $ r ) { return ( string ) $ r -> path ; } , $ signInfo ) , $ apiCheckFee ) ; }
!! INTERNAL METHOD, public for testing purposes !!
create, sign and send transction based on inputs and outputs

@param Transaction $tx
@param SignInfo[]  $signInfo
@param bool $apiCheckFee     let the API check if the fee is correct
@return string
@throws \Exception
@internal
!! INTERNAL METHOD public for testing purposes !! create sign and send transction based on inputs and outputs