Mercurial > hg > Database > jungle-sharp
view Test/jungle-network/operations/NetworkPutAttributeOperationTest.cs @ 38:e954d456665c
library is made by rake
author | Shinji KONO <kono@ie.u-ryukyu.ac.jp> |
---|---|
date | Wed, 22 Feb 2017 16:58:10 +0900 |
parents | 1466993c104c |
children |
line wrap: on
line source
// using UnityEngine; using System.Collections; using MsgPack; using System; using JungleDB; public class NetworkPutAttributeOperationTest : MonoBehaviour { // Use this for initialization void Start () { byte[] value = System.Text.ASCIIEncoding.UTF8.GetBytes("test"); NetworkPutAttributeOperation op = new NetworkPutAttributeOperation("hoge", value); ObjectPacker pack = new ObjectPacker(); // send this byte to server. byte[] packValue = pack.Pack(op); ObjectPacker unpack = new ObjectPacker(); NetworkPutAttributeOperation nOp = unpack.Unpack<NetworkPutAttributeOperation>(packValue); print (nOp.getCommand()); } }