Пример #1
0
        public static PushPayload PushObject_android_with_options()
        {
            PushPayload pushPayload = new PushPayload()
            {
                platform = Platform.android_ios()
            };

            pushPayload.audience = Audience.s_registrationId();

            AndroidNotification androidnotification = new AndroidNotification();

            androidnotification.setAlert("Push Object android with options");
            androidnotification.setBuilderID(3);
            androidnotification.setStyle(1);
            androidnotification.setAlert_type(1);
            androidnotification.setBig_text("big text content");
            androidnotification.setInbox("JSONObject");
            androidnotification.setBig_pic_path("picture url");
            androidnotification.setPriority(0);
            androidnotification.setCategory("category str");

            var notification = new Notification().setAlert("alert content");

            notification.AndroidNotification = androidnotification;
            notification.IosNotification     = new IosNotification();
            notification.IosNotification.incrBadge(1);
            notification.IosNotification.AddExtra("extra_key", "extra_value");
            pushPayload.notification = notification.Check();
            return(pushPayload);
        }