示例#1
0
        static public QBitNinja.Client.Models.BalanceSummaryDetails Create(BalanceSummaryDetails details)
        {
            var result = new QBitNinja.Client.Models.BalanceSummaryDetails();

            result.TransactionCount = details.transactionCount;
            result.Amount           = details.amount;
            result.Received         = details.received;
            result.Assets           = AssetBalanceSummaryDetails.Create(details.assets);

            return(result);
        }
示例#2
0
        public QBitNinja.Client.Models.BalanceSummary Result()
        {
            //UnityEngine.Debug.Log(UnityEngine.JsonUtility.ToJson(this,true));

            var result = new QBitNinja.Client.Models.BalanceSummary();

            result.UnConfirmed   = BalanceSummaryDetails.Create(unConfirmed);
            result.Confirmed     = BalanceSummaryDetails.Create(confirmed);
            result.Spendable     = BalanceSummaryDetails.Create(spendable);
            result.Immature      = BalanceSummaryDetails.Create(immature);
            result.OlderImmature = olderImmature;

            if (cacheHit != null && cacheHit.Length > 0)
            {
                result.CacheHit = (QBitNinja.Client.Models.CacheHit)Enum.Parse(typeof(QBitNinja.Client.Models.CacheHit), cacheHit, true);
            }

            return(result);
        }