I am trying to convert Parse to Clevertap in the application I'm working on. I have tried looking at https://blog.clevertap.com/transitioning-from-parse-push-notifications/ but haven't had much luck on what I'm trying to accomplish.
In the method that needs to be converted, I am wanting the user to have the ability to subscribe and unsubscribe from a channel using:
private class AllPushClickListener implements View.OnClickListener {
private AppFeed mAppFeed;
public AllPushClickListener(AppFeed appFeed) {
mAppFeed = appFeed;
}
@Override
public void onClick(View v) {
Log.d(TAG, "subscribing to " + getPushChannelName(mAppFeed) + "_all");
ParsePush.unsubscribeInBackground(getPushChannelName(mAppFeed) + "_top");
ParsePush.subscribeInBackground(getPushChannelName(mAppFeed) + "_all");
mAppFeed.setPushNotificationsOn(true);
mAppFeed.setReceiveTopNotifications(false);
mAppFeed.setChannelName(getPushChannelName(mAppFeed) + "_all");
hideNotificationButtons();
mPushAllStoriesSelectedButton.setVisibility(View.VISIBLE);
mPersistedFeedDaoHelper.createOrUpdate(mAppFeed);
}
}
Not sure how to transition this into Clevertap.
Thanks for the help.