Beispiel #1
0
 public static SavedTxIn FromTxIn(TxIn tx)
 {
     return(new SavedTxIn
     {
         Sequence = tx.Sequence,
         ScriptSig = tx.ScriptSig.ToString(),
         WitScript = tx.WitScript.ToString(),
         IsFinal = tx.IsFinal,
         PrevOut = SavedOutPoint.FromOutPoint(tx.PrevOut)
     });
 }
Beispiel #2
0
        public static SavedPosParameters FromPosParameters(PosParameters pos)
        {
            var posParams = new SavedPosParameters
            {
                HashProof       = pos.HashProof.ToString(),
                Mint            = pos.Mint,
                Flags           = (int)pos.Flags,
                StakeModifier   = pos.StakeModifier,
                StakeModifierV2 = pos.StakeModifierV2.ToString(),
                StakeTime       = pos.StakeTime,
                PrevoutStake    = SavedOutPoint.FromOutPoint(pos.PrevoutStake)
            };

            return(posParams);
        }