Example #1
0
        public static List <int> GetRegisterNotification()
        {
            string     text = string.Empty;
            List <int> list = new List <int>();

            try
            {
                text = NpPushAndroid.GetRegisterNotification();
                if (string.IsNullOrEmpty(text))
                {
                    return(null);
                }
                string[] array = text.Split(new char[]
                {
                    ','
                });
                foreach (string text2 in array)
                {
                    try
                    {
                        list.Add(int.Parse(text2));
                    }
                    catch (FormatException)
                    {
                        global::Debug.Log("GetRegisterNotification : Invalid parameter requestCode = " + text2);
                        list = null;
                        break;
                    }
                }
            }
            catch (Exception)
            {
                global::Debug.Log("GetRegisterNotification : unexpected error.");
                list = null;
            }
            return(list);
        }
Example #2
0
 public static void CancelLocalNotifications(int requestCode)
 {
     NpPushAndroid.CancelLocalNotifications(requestCode);
 }
Example #3
0
 public static void CancelAllLocalNotifications()
 {
     NpPushAndroid.CancelAllLocalNotifications();
 }
Example #4
0
 public static void LocalPushSend(int type, string alertBody, int badgeCount, int second)
 {
     NpPushAndroid.LocalPushSend(type, alertBody, second);
 }
Example #5
0
 public static void LocalPushSendRequestCode(string alertBody, int badgeCount, int second, int requestCode)
 {
     NpPushAndroid.LocalPushSendRequestCode(alertBody, second, requestCode);
 }
Example #6
0
 public void GetDeviceToken(string senderId)
 {
     NpPushAndroid.GetDeviceToken(this.mCallBackReceiveObjName, senderId);
 }