Class MessagesAPI
- java.lang.Object
-
- com.cheetahdigital.corekit.models.module.Controller
-
- com.cheetahdigital.messages.core.api.MessagesAPI
-
- All Implemented Interfaces:
RestController
public class MessagesAPI extends Controller
Cheetah Loyalty Messages Module AMessage
represents one Push Message/Notification.
-
-
Field Summary
-
Fields inherited from class com.cheetahdigital.corekit.models.module.Controller
STANDARD_DATE_FORMAT, TIMEZONE_DATE_FORMAT
-
-
Constructor Summary
Constructors Constructor Description MessagesAPI()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
dismissMessage(MessagesParams messagesParams, Listener<SuccessResponse> callback)
Dismisses a message of the uservoid
getMessages(MessagesParams messagesParams, boolean clearCache, ListenerModel<BaseModel<Messages>,Messages> listener)
Get the messages of the user-
Methods inherited from class com.cheetahdigital.corekit.models.module.Controller
createCache, createHttpClient, createRetrofitInterface, evictAllCache, getGsonConfiguration, getRestAdapter, getTimeoutConnectionInSeconds, getTimeoutSocketInSeconds, initialize, removeResponsesFromCache
-
-
-
-
Method Detail
-
getMessages
public void getMessages(MessagesParams messagesParams, boolean clearCache, ListenerModel<BaseModel<Messages>,Messages> listener)
Get the messages of the user- Parameters:
messagesParams
- theMessagesParams
for Connections APIclearCache
- clear previously stored cachelistener
- listener if list of connections is successfully received
-
dismissMessage
public void dismissMessage(MessagesParams messagesParams, Listener<SuccessResponse> callback)
Dismisses a message of the user- Parameters:
messagesParams
- theMessagesParams
for Connections APIcallback
- callback to handle success or failed request
-
-