コード例 #1
0
        // ...

        public System.Web.Http.IHttpActionResult Register(string id,
                                                          string notificationType)
        {
            User user = userService.LoadUser(id);

            userService.RegisterForNotifications(user,
                                                 NotificationType.FromString(notificationType));
            return(Ok());
        }
コード例 #2
0
        public void Unregister(string userId, string notificationType)
        {
            User user = userService.LoadUser(userId);

            userService.UnregisterForNotifications(user, NotificationType.FromString(notificationType));
        }