Interface Invitation
-
- All Known Implementing Classes:
SFSInvitation
public interface Invitation
Represents an Invitation object
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description InvitationCallback
getCallback()
Obtain a reference to the CallBack handler classint
getExpiryTime()
The expiration timestamp.int
getId()
Get the unique invitation IDUser
getInvitee()
Get the Invitee, the user that receives the invitationUser
getInviter()
Get the Inviter, the user that started this invitationISFSObject
getParams()
An SFSObject of custom parameters can be attached to the invitation.int
getSecondsForAnswer()
The amount of seconds given to the invitee to respond to the invitationboolean
isExpired()
Checks if the invitation is expired.void
setCallback(InvitationCallback callback)
Set the CallBack handler for the invitation.void
setParams(ISFSObject params)
An SFSObject of custom parameters can be attached to the invitation.
-
-
-
Method Detail
-
getId
int getId()
Get the unique invitation ID- Returns:
- the id
-
getInviter
User getInviter()
Get the Inviter, the user that started this invitation- Returns:
- the inviter
-
getInvitee
User getInvitee()
Get the Invitee, the user that receives the invitation- Returns:
- the invitee
-
isExpired
boolean isExpired()
Checks if the invitation is expired.- Returns:
- true if the invitation is expired
-
getExpiryTime
int getExpiryTime()
The expiration timestamp.- Returns:
- expiration timestamp.
-
getSecondsForAnswer
int getSecondsForAnswer()
The amount of seconds given to the invitee to respond to the invitation- Returns:
- the amount of seconds given to the invitee to respond to the invitation
-
getCallback
InvitationCallback getCallback()
Obtain a reference to the CallBack handler class- Returns:
- the callback handler
- See Also:
InvitationCallback
-
setCallback
void setCallback(InvitationCallback callback)
Set the CallBack handler for the invitation. The handler will be invoked by the system when the invited User accepts or refuses the invitation or if the invitation expires.- Parameters:
callback
- the callback handler- See Also:
InvitationCallback
-
getParams
ISFSObject getParams()
An SFSObject of custom parameters can be attached to the invitation. It could contain any properties relevant to the invitation, like a message, the game type/settings and any other parameter.- Returns:
- the custom parameters
- See Also:
SFSObject
-
setParams
void setParams(ISFSObject params)
An SFSObject of custom parameters can be attached to the invitation. It could contain any properties relevant to the invitation, like a message, the game type/settings and any other parameter.- Parameters:
params
- the custom parameters- See Also:
SFSObject
-
-