예제 #1
0
        public ViewSyncParams SerializeAll()
        {
            ViewSyncParams paramss = new ViewSyncParams();

            foreach (var view in ID2Views.Values)
            {
                ViewSyncDataParams param = view.Serialize();
                paramss.VsdParams.Add(param);
            }

            return(paramss);
        }
예제 #2
0
        public ViewSyncDataParams Serialize()
        {
            NGViewStream stream = new NGViewStream();

            foreach (var component in ViewComponents)
            {
                var synccomponent = component as INGSerialize;
                if (synccomponent != null)
                {
                    synccomponent.SerializeViewComponent(stream);
                }
            }

            ViewSyncDataParams param = new ViewSyncDataParams();

            param.ViewID = ViewID;
            param.ViewSyncData.AddRange(stream.mSendStream);

            return(param);
        }