public PhotoNotificationData(
     NotificationFlag type, string id, string rawNoticedDate, string title, string summary,
     Uri linkUrl, string[] imagesUrl, DateTime noticedDate)
     : base(type, id, rawNoticedDate, title, summary, noticedDate)
 {
     LinkUrl = linkUrl;
     ImagesUrl = imagesUrl;
 }
 public HangoutNotificationData(
     NotificationFlag type, string id, string rawNoticedDate, string title, string summary,
     Uri linkUrl, ProfileData actor, DateTime noticedDate)
     : base(type, id, rawNoticedDate, title, summary, noticedDate)
 {
     LinkUrl = linkUrl;
     Actor = actor;
 }
Example #3
0
 public UtilService(IDbService dbService, UserService userService, CourseService courseService,
                    LanguageService languageService, NotificationFlag notificationFlag)
 {
     _dbService        = dbService;
     _userService      = userService;
     _courseService    = courseService;
     _languageService  = languageService;
     _notificationFlag = notificationFlag;
 }
 public NotificationData(
     NotificationFlag type, string id, string rawNoticedDate, string title, string summary, DateTime noticedDate)
 {
     Type = type;
     Id = id;
     RawNoticedDate = rawNoticedDate;
     Title = title;
     Summary = summary;
     NoticedDate = noticedDate;
 }
Example #5
0
        public void Claim(Action <int> onClaim)
        {
            if (PendingClaim > 0)
            {
                PendingClaim = 0;
                ClaimedCount++;
                _notifyStatus = NotificationFlag.Ready;

                onClaim.SafeInvoke(GetCummulitiveReward());
            }
        }
Example #6
0
 public SubmitSolutionService(IDbService dBService, IdService idService, LanguageService languageService,
                              CourseService courseService, UserService userService, NotificationFlag notificationFlag,
                              ILogger <SubmitSolutionService> logger)
 {
     _dbService        = dBService;
     _idService        = idService;
     _languageService  = languageService;
     _courseService    = courseService;
     _userService      = userService;
     _logger           = logger;
     _notificationFlag = notificationFlag;
 }
Example #7
0
        public void Initialize()
        {
            if (!_isInitialized)
            {
                CurrentTarget   = InitialValue;
                Currentprogress = 0;
                ClaimedCount    = 0;
                PendingClaim    = 0;

                _isInitialized = true;
                _notifyStatus  = NotificationFlag.Ready;
            }
        }
Example #8
0
        public void SetProgress(int progress, Action <int> onObjectiveComplete = null, Action fireNotification = null)
        {
            Currentprogress += progress;
            if (Currentprogress >= CurrentTarget)
            {
                CurrentTarget += IncrementalValue;
                PendingClaim++;

                onObjectiveComplete.SafeInvoke(PendingClaim);

                if (_notifyStatus == NotificationFlag.Ready)
                {
                    fireNotification.SafeInvoke();
                    _notifyStatus = NotificationFlag.Notified;
                }
            }
        }
 public NotificationItemData(ProfileData actor, NotificationFlag type, string rawData)
 {
     Actor = actor;
     Type = type;
     RawData = rawData;
 }
 public SocialNotificationData(
     NotificationFlag type, string id, string rawNoticedDate, string title, string summary,
     NotificationItemData[] logItems, DateTime noticedDate)
     : base(type, id, rawNoticedDate, title, summary, noticedDate) { LogItems = logItems; }