Exemplo n.º 1
0
        public VnthTransfer DeserializeJson(string json)
        {
            var transfer = new VnthTransfer();

            //stream to object

            return transfer;
        }
Exemplo n.º 2
0
        public VnthTransfer DeserializeJson(string json)
        {
            var transfer = new VnthTransfer();

            //stream to object



            return(transfer);
        }
Exemplo n.º 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);
        }
Exemplo n.º 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);
        }