public void SaveAndLoad()
        {
            var campaign = "campaign";
            var name     = "save1";
            var data1    = new DataContainer {
                value = 42
            };

            Assert.True(_service.Save(campaign, name, data1));
            Assert.True(_service.Load(campaign, name, out DataContainer data2));

            Assert.AreEqual(data1.value, data2.value);
        }
Beispiel #2
0
        public async void Login(PassportVo tryLogin)
        {
            this.userVo = await this.net.Send <UserVo>(ActionIDDefine.Login, new Dictionary <string, string> {
                { "Pid", tryLogin.username },
                { "Pwd", tryLogin.password }
            }, (ErrorInfo e) =>
            {
                App.Facade.SendNotification(NoticeConst.LOGIN_FAILED, e);
            });

            save.Save <string>("pid", tryLogin.username);
            Facade.SendNotification(NoticeConst.LOGIN_SUCCESS);
        }
Beispiel #3
0
 void OnGUI()
 {
     GUILayout.BeginVertical();
     if (GUILayout.Button("Modify"))
     {
         someService.ChangeValues();
     }
     if (GUILayout.Button("Save"))
     {
         saveService.Save(someService);
     }
     GUILayout.EndVertical();
 }
Beispiel #4
0
        public ServiceDetail SaveService(SaveService ss)
        {
            Debug.Enter();
            ServiceDetail sd = new ServiceDetail();

            try
            {
                ss.Save();
                sd.BusinessServices = ss.BusinessServices;
            }
            catch (Exception e)
            {
                DispositionReport.Throw(e);
            }

            return(sd);
        }
Beispiel #5
0
 public void Save()
 {
     saveService.Save();
 }
Beispiel #6
0
 public Record Update([FromBody] Record record)
 {
     return(SaveService.Save(record));
 }