コード例 #1
0
ファイル: ApiViewModel.cs プロジェクト: jbubicz/uwp_tutorials
 public ApiViewModel(IInteractionService interactionService)
 {
     _interactionService = interactionService;
     if (IsInDesignModeStatic)
     {
         var syncActionInfo = new SyncActionInformation(SyncAction.CreateUser);
         syncActionInfo.SetSyncActionResult(SyncActionError.None);
         SyncActionInformations.Add(syncActionInfo);
         syncActionInfo = new SyncActionInformation(SyncAction.CreateDevice);
         syncActionInfo.SetSyncActionResult(SyncActionError.None);
         SyncActionInformations.Add(syncActionInfo);
         syncActionInfo = new SyncActionInformation(SyncAction.SaveEntity);
         SyncActionInformations.Add(syncActionInfo);
     }
 }
コード例 #2
0
        public MockApiViewModel()
        {
            var obj = new SyncActionInformation(SyncAction.CreateUser);

            obj.SetSyncActionResult(SyncActionError.None);
            SyncActionInformations.Add(obj);
            obj = new SyncActionInformation(SyncAction.CreateDevice);
            obj.SetSyncActionResult(SyncActionError.None);
            SyncActionInformations.Add(obj);
            obj = new SyncActionInformation(SyncAction.GetDefaultCollection);
            obj.SetSyncActionResult(SyncActionError.None);
            SyncActionInformations.Add(obj);
            obj = new SyncActionInformation(SyncAction.SaveCollection);
            SyncActionInformations.Add(obj);

            RequestCount = 4;
        }