public class

StaticList

extends Object
java.lang.Object
   ↳ com.ad4screen.sdk.StaticList

Class Overview

This StaticList object can be used in order to subscribe/unsubscribe
and get the subscription status of a user/device to a list.
This list must be explicitely defined server-side before the SDK can interact with it
The parameter listId is always the server-side id of the list you want to subscribe/unsubscribe or get status for

See Also

Summary

Constants
int SUBSCRIBED
int UNSUBSCRIBED
Public Constructors
StaticList(String listId, Date expireAt)
Create a StaticList with expiration date
StaticList(String listId)
Create a standard StaticList
Public Methods
Date getExpireAt()
Getter for expiration date
String getListId()
Getter for the ListId
String getName()
Getter for the name
int getStatus()
Returns the subscription status for a given list
boolean isSubscribed()
Is the user subscribed to a given list ?
[Expand]
Inherited Methods
From class java.lang.Object

Constants

public static final int SUBSCRIBED

Constant Value: 2 (0x00000002)

public static final int UNSUBSCRIBED

Constant Value: 4 (0x00000004)

Public Constructors

public StaticList (String listId, Date expireAt)

Create a StaticList with expiration date

Parameters
listId Id given to the list on the server-side
expireAt Is the date on which the subscription ends

public StaticList (String listId)

Create a standard StaticList

Parameters
listId Id given to the list on the server-side

Public Methods

public Date getExpireAt ()

Getter for expiration date

Returns
  • the date on which the subscription ends

public String getListId ()

Getter for the ListId

Returns
  • the List's id set on server side

public String getName ()

Getter for the name

Returns
  • the name given to the list on server side

public int getStatus ()

Returns the subscription status for a given list

Returns
  • StaticList.SUBSCRIBED if subscribed or StaticList.UNSUBSCRIBED if unsubscribed

public boolean isSubscribed ()

Is the user subscribed to a given list ?

Returns
  • true if he's subscribed to the list, false otherwise