Ejemplo n.º 1
0
        public static XQFOCCQ33600OutBlock2 FromQuery(XQFOCCQ33600 query)
        {
            XQFOCCQ33600OutBlock2 block = new XQFOCCQ33600OutBlock2();

            block.IsValidData   = true;
            block.InvalidReason = "";
            if (query.QueryResult != null && query.QueryResult.IsSystemError == true)
            {
                block.IsValidData   = false;
                block.InvalidReason = query.ReceiveMessage;
                return(block);
            }
            try
            {
                block.RecCnt           = query.GetFieldData(block.GetBlockName(), "RecCnt", 0).ParseLong("RecCnt");                     // long 5
                block.AcntNm           = query.GetFieldData(block.GetBlockName(), "AcntNm", 0).TrimEnd('?');                            // char 40
                block.BnsctrAmt        = query.GetFieldData(block.GetBlockName(), "BnsctrAmt", 0).ParseLong("BnsctrAmt");               // long 16
                block.MnyinAmt         = query.GetFieldData(block.GetBlockName(), "MnyinAmt", 0).ParseLong("MnyinAmt");                 // long 16
                block.MnyoutAmt        = query.GetFieldData(block.GetBlockName(), "MnyoutAmt", 0).ParseLong("MnyoutAmt");               // long 16
                block.InvstAvrbalPramt = query.GetFieldData(block.GetBlockName(), "InvstAvrbalPramt", 0).ParseLong("InvstAvrbalPramt"); // long 16
                block.InvstPlAmt       = query.GetFieldData(block.GetBlockName(), "InvstPlAmt", 0).ParseLong("InvstPlAmt");             // long 16
                block.InvstErnrat      = query.GetFieldData(block.GetBlockName(), "InvstErnrat", 0).ParseDouble("InvstErnrat");         // double 9.2
            } catch (InvalidDataFormatException e) {
                block.IsValidData   = false;
                block.InvalidReason = $"FieldName == {e.DataFieldName}, FieldData == \"{e.DataValue}\"";
            }
            return(block);
        }
Ejemplo n.º 2
0
        public XQFOCCQ33600OutBlock2 GetBlock2()
        {
            XQFOCCQ33600OutBlock2 instance = XQFOCCQ33600OutBlock2.FromQuery(this);

            return(instance);
        }