Append Unconfirmed TXRef to the list.

@param \BlockCypher\Api\TXRef $unconfirmedTxref
@return $this
335013
public function addUnconfirmedTxref($unconfirmedTxref)
    {
        if (!$this->getUnconfirmedTxrefs()) {
            return $this->setUnconfirmedTxrefs(array($unconfirmedTxref));
        } else {
            return $this->setUnconfirmedTxrefs(
                array_merge($this->getUnconfirmedTxrefs(), array($unconfirmedTxref))
            );
        }
    }
531744
@Override
    public boolean addRef(Object object)
        throws IOException
    {
        if (_isUnshared) {
            _refCount++;
            return false;
        }

        int newRef = _refCount;

        int ref = addRef(object, newRef, false);

        if (ref != newRef) {
            writeRef(ref);

            return true;
        }
        else {
            _refCount++;

            return false;
        }
    }
300012
public function verify($transactionRef)
    {
        $transactionData = $this->getTransactionResource()->verify($transactionRef);

        if ($transactionData instanceof \Exception) {
            throw $transactionData;
        }

        if ($transactionData['status'] == TransactionContract::TRANSACTION_STATUS_SUCCESS) {
            return [
                'authorization' => $transactionData['authorization'],
                'customer'      => $transactionData['customer'],
                'amount'        => $transactionData['amount'],
                'plan'          => $transactionData['plan'],
            ];
        }

        return false;
    }
851519
public function sendTx(TransactionBuilder $txBuilder, $apiCheckFee = true) {
        list($tx, $signInfo) = $this->buildTx($txBuilder);

        return $this->_sendTx($tx, $signInfo, $apiCheckFee);
    }
1361588
function commit() {
		$this->savepoint--;

		if ($this->savepoint == 0) {
			$this->dbh->commit();
		}
		else { // not finished with transaction yet
			$this->dbh->exec('RELEASE SAVEPOINT save'.$this->savepoint);
		}

		return $this;
	}
458837
function add(Expr $next) {
		if ($this->isNull()) {
			throw new \UnexpectedValueException("Cannot add anything to NULL");
		}
		if ($this->next) {
			$this->next->add($next);
		} else {
			$this->next = $next;
		}
		return $this;
	}
739355
private static void addRef(Map refs, String key, JSDynamic unres) {
    List thisKey = (List) refs.get(key);
    if (thisKey == null) {
      thisKey = new ArrayList();
      refs.put(key, thisKey);
    }
    thisKey.add(unres);
  }
192569
protected function addWithoutNotApproved(Builder $builder): void
    {
        $builder->macro('withoutNotApproved', function (Builder $builder) {
            return $builder->withoutGlobalScope($this)->whereNotNull('approved_at');
        });
    }
602160
def set_XRef(self, X=None, indtX=None, indtXlamb=None):
        
        out = self._checkformat_inputs_XRef(X=X, indtX=indtX,
                                            indXlamb=indtXlamb)
        X, nnch, indtX, indXlamb, indtXlamb = out
        self._ddataRef['X'] = X
        self._ddataRef['nnch'] = nnch
        self._ddataRef['indtX'] = indtX
        self._ddataRef['indtXlamb'] = indtXlamb
        self._ddata['uptodate'] = False
63300
public function addTx($tx)
    {
        if (!$this->getTxs()) {
            return $this->setTxs(array($tx));
        } else {
            return $this->setTxs(
                array_merge($this->getTxs(), array($tx))
            );
        }
    }
1096017
public function buildTx(TransactionBuilder $txBuilder) {
        $send = $txBuilder->getOutputs();
        $utxos = $txBuilder->getUtxos();
        $signInfo = [];

        $txb = new TxBuilder();

        foreach ($utxos as $utxo) {
            if (!$utxo->address || !$utxo->value || !$utxo->scriptPubKey) {
                $tx = $this->sdk->transaction($utxo->hash);

                if (!$tx || !isset($tx['outputs'][$utxo->index])) {
                    throw new \Exception("Invalid output [{$utxo->hash}][{$utxo->index}]");
                }

                $output = $tx['outputs'][$utxo->index];

                if (!$utxo->address) {
                    $utxo->address = $this->addressReader->fromString($output['address']);
                }
                if (!$utxo->value) {
                    $utxo->value = $output['value'];
                }
                if (!$utxo->scriptPubKey) {
                    $utxo->scriptPubKey = ScriptFactory::fromHex($output['script_hex']);
                }
            }

            if (SignInfo::MODE_SIGN === $utxo->signMode) {
                if (!$utxo->path) {
                    $utxo->path = $this->getPathForAddress($utxo->address->getAddress());
                }

                if (!$utxo->redeemScript || !$utxo->witnessScript) {
                    list(, $redeemScript, $witnessScript) = $this->getRedeemScriptByPath($utxo->path);
                    $utxo->redeemScript = $redeemScript;
                    $utxo->witnessScript = $witnessScript;
                }
            }

            $signInfo[] = $utxo->getSignInfo();
        }

        $utxoSum = array_sum(array_map(function (UTXO $utxo) {
            return $utxo->value;
        }, $utxos));
        if ($utxoSum < array_sum(array_column($send, 'value'))) {
            throw new \Exception("Atempting to spend more than sum of UTXOs");
        }

        list($fee, $change) = $this->determineFeeAndChange($txBuilder, $this->getHighPriorityFeePerKB(), $this->getOptimalFeePerKB(), $this->getLowPriorityFeePerKB());

        if ($txBuilder->getValidateFee() !== null) {
            // sanity check to make sure the API isn't giving us crappy data
            if (abs($txBuilder->getValidateFee() - $fee) > (Wallet::BASE_FEE * 5)) {
                throw new \Exception("the fee suggested by the coin selection ({$txBuilder->getValidateFee()}) seems incorrect ({$fee})");
            }
        }

        if ($change > 0) {
            $send[] = [
                'address' => $txBuilder->getChangeAddress() ?: $this->getNewChangeAddress(),
                'value' => $change
            ];
        }

        foreach ($utxos as $utxo) {
            $txb->spendOutPoint(new OutPoint(Buffer::hex($utxo->hash), $utxo->index));
        }

        // outputs should be randomized to make the change harder to detect
        if ($txBuilder->shouldRandomizeChangeOuput()) {
            $this->sdk->shuffle($send);
        }

        foreach ($send as $out) {
            assert(isset($out['value']));

            if (isset($out['scriptPubKey'])) {
                $txb->output($out['value'], $out['scriptPubKey']);
            } elseif (isset($out['address'])) {
                $txb->output($out['value'], $this->addressReader->fromString($out['address'])->getScriptPubKey());
            } else {
                throw new \Exception();
            }
        }

        return [$txb->get(), $signInfo];
    }
511460
public function showConfirmButton($btnText = 'Ok', $btnColor = '#3085d6')
    {
        $this->config['showConfirmButton'] = true;
        $this->config['confirmButtonText'] = $btnText;
        $this->config['confirmButtonColor'] = $btnColor;
        $this->config['allowOutsideClick'] = false;
        $this->removeTimer();
        $this->flash();

        return $this;
    }
14610
public function setConfirmation(array $confirmation)
    {
        if (! array_key_exists('text', $confirmation)) {
            throw InvalidConfirmationHash::missingTextField();
        }

        $this->confirmation = $confirmation;

        return $this;
    }
651736
public function unsetLimit($unset_offset = true): self
    {
        $this->limit = null;
        if ($unset_offset) {
            $this->offset = null;
        }

        return $this;
    }
829244
public function setStockTransfer(\Flowcode\ShopBundle\Entity\StockTransfer $stockTransfer = null)
    {
        $this->stockTransfer = $stockTransfer;

        return $this;
    }
466608
public static TransactionEdit createTruncateInvalidTxBefore(long truncateInvalidTxTime) {
    return new TransactionEdit(0L, 0L, State.TRUNCATE_INVALID_TX, 0L, null, 0L, false, null, null, 
                               truncateInvalidTxTime, 0L, null);
  }
236416
public function setSaved($saved = true)
    {
        $this->each(
            function(Record $record) use ($saved) {
                $record->setSaved($saved);
            }
        );

        return $this;
    }