コード例 #1
0
        public VnthTransfer DeserializeJson(string json)
        {
            var transfer = new VnthTransfer();

            //stream to object

            return transfer;
        }
コード例 #2
0
        public VnthTransfer DeserializeJson(string json)
        {
            var transfer = new VnthTransfer();

            //stream to object



            return(transfer);
        }
コード例 #3
0
        public void SerializeJson()
        {
            VnthTransfer transfer = new VnthTransfer()
            {
                SourceInfo = new VnthAccountInfo(),
                DestinationInfo = new VnthAccountInfo(),
                TransferType = TransferType.Outcome,
                Amount  = 12,
                TitleOfTransfer = "",
                DateOfTransfer = new DateTime(),
                DateOfRecord = new DateTime()
            };

            DataContractJsonSerializer serializer = new DataContractJsonSerializer(typeof(VnthTransfer));

            MemoryStream stream = new MemoryStream();

            serializer.WriteObject(stream, transfer);
        }
コード例 #4
0
        public void SerializeJson()
        {
            VnthTransfer transfer = new VnthTransfer()
            {
                SourceInfo      = new VnthAccountInfo(),
                DestinationInfo = new VnthAccountInfo(),
                TransferType    = TransferType.Outcome,
                Amount          = 12,
                TitleOfTransfer = "",
                DateOfTransfer  = new DateTime(),
                DateOfRecord    = new DateTime()
            };

            DataContractJsonSerializer serializer = new DataContractJsonSerializer(typeof(VnthTransfer));

            MemoryStream stream = new MemoryStream();

            serializer.WriteObject(stream, transfer);
        }