Exemple #1
0
        /// <summary>
        /// Checks whether a notification channel with the given ID exists.
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void OnClickChannelExists(object sender, System.EventArgs e)
        {
            string Tag = "ChannelExists";

            try
            {
                bool isExist = NotificationController.ChannelExists(this, CoreConstants.NotificationChannelId + 49);
                if (isExist)
                {
                    log.Info(Tag, "The channel exists!");
                }
                else
                {
                    log.Info(Tag, "The channel does not exist!");
                }
            }
            catch (ApiException exception)
            {
                log.Error(Tag, "Error/Exception: " + exception);
            }
        }
 public bool ChannelExists(string channelId)
 {
     return(NotificationController.ChannelExists(Application.Context, channelId));
 }