BitSharper.Transaction.ConnectForReorganize C# (CSharp) Method

ConnectForReorganize() private method

Connects all inputs using the provided transactions. If any input cannot be connected returns that input or null on success.
private ConnectForReorganize ( Transaction>.IDictionary transactions ) : TransactionInput
transactions Transaction>.IDictionary
return TransactionInput
        internal TransactionInput ConnectForReorganize(IDictionary<Sha256Hash, Transaction> transactions)
        {
            foreach (var input in _inputs)
            {
                // Coinbase transactions, by definition, do not have connectable inputs.
                if (input.IsCoinBase) continue;
                var result = input.Connect(transactions, false);
                // Connected to another tx in the wallet?
                if (result == TransactionInput.ConnectionResult.Success)
                    continue;
                // The input doesn't exist in the wallet, eg because it belongs to somebody else (inbound spend).
                if (result == TransactionInput.ConnectionResult.NoSuchTx)
                    continue;
                // Could not connect this input, so return it and abort.
                return input;
            }
            return null;
        }