BuildIt.Bot.Client.Impl.Droid.BotClientActivityBase.TryCleaningToastNotificationHistory C# (CSharp) Method

TryCleaningToastNotificationHistory() private method

private TryCleaningToastNotificationHistory ( ) : bool
return bool
        private bool TryCleaningToastNotificationHistory()
        {
            try
            {
                var notificationManager = GetSystemService(NotificationService) as NotificationManager;
                if (notificationManager != null)
                {
                    notificationManager.CancelAll();
                    return true;
                }
            }
            catch (Exception e)
            {
                Debug.WriteLine(e);
            }

            return false;
        }
    }