-
public class CTDisplayUnitControllerController class for caching & supplying the Display Units to the client.
-
-
Method Summary
Modifier and Type Method Description synchronized ArrayList<CleverTapDisplayUnit>getAllDisplayUnits()Getter for retrieving all the running Display Units in the cache. synchronized CleverTapDisplayUnitgetDisplayUnitForID(String unitId)Getter to retrieve the Display Unit using the unitID synchronized voidreset()clears the existing Display Units synchronized ArrayList<CleverTapDisplayUnit>updateDisplayUnits(JSONArray messages)Replaces the old Display Units with the new ones, post transformation of Json objects to Display Unit objects -
-
Method Detail
-
getAllDisplayUnits
@Nullable() synchronized ArrayList<CleverTapDisplayUnit> getAllDisplayUnits()
Getter for retrieving all the running Display Units in the cache.
-
getDisplayUnitForID
@Nullable() synchronized CleverTapDisplayUnit getDisplayUnitForID(String unitId)
Getter to retrieve the Display Unit using the unitID
- Parameters:
unitId- - unitID of the Display Unit getUnitID
-
reset
synchronized void reset()
clears the existing Display Units
-
updateDisplayUnits
@Nullable() synchronized ArrayList<CleverTapDisplayUnit> updateDisplayUnits(JSONArray messages)
Replaces the old Display Units with the new ones, post transformation of Json objects to Display Unit objects
- Parameters:
messages- - json-array of Display Unit items
-
-
-
-