Packagecom.distriqt.extension.facebook.gamingservices.content
Classpublic class GameRequestContentBuilder
InheritanceGameRequestContentBuilder Inheritance Object

Helper class to construct the content for the Game Request Dialog.



Public Methods
 MethodDefined By
  
GameRequestContentBuilder
  
build():Object
Returns an object to pass to the show() function to display a game request dialog.
GameRequestContentBuilder
  
Sets the action type for this request
GameRequestContentBuilder
  
Sets optional data which can be used for tracking; maximum length is 255 characters
GameRequestContentBuilder
  
Sets the message users receiving the request will see.
GameRequestContentBuilder
  
Sets the open graph id of the object that action type will be performed on.
GameRequestContentBuilder
  
An array of user IDs, usernames or invite tokens of people to send request.
GameRequestContentBuilder
  
Sets an optional title for the dialog; maximum length is 50 characters.
GameRequestContentBuilder
Public Constants
 ConstantDefined By
  TAG : String = GameRequestContentBuilder
[static]
GameRequestContentBuilder
Constructor Detail
GameRequestContentBuilder()Constructor
public function GameRequestContentBuilder()



Method Detail
build()method
public function build():Object

Returns an object to pass to the show() function to display a game request dialog.

Returns
Object — Content object.
setActionType()method 
public function setActionType(actionType:String):GameRequestContentBuilder

Sets the action type for this request

Parameters

actionType:String — The action type from the defined constants in the ActionType class

Returns
GameRequestContentBuilderGameRequestContentBuilder instance for chaining calls

See also

ActionType.SEND
ActionType.ASKFOR
ActionType.TURN
setData()method 
public function setData(data:String):GameRequestContentBuilder

Sets optional data which can be used for tracking; maximum length is 255 characters

Parameters

data:String — The data

Returns
GameRequestContentBuilderGameRequestContentBuilder instance for chaining calls
setMessage()method 
public function setMessage(message:String):GameRequestContentBuilder

Sets the message users receiving the request will see. The maximum length is 60 characters.

Parameters

message:String — the message

Returns
GameRequestContentBuilderGameRequestContentBuilder instance for chaining calls
setObjectId()method 
public function setObjectId(objectId:String):GameRequestContentBuilder

Sets the open graph id of the object that action type will be performed on. Only valid (and required) for ActionTypes SEND, ASKFOR

Parameters

objectId:String — the object id

Returns
GameRequestContentBuilderGameRequestContentBuilder instance for chaining calls
setRecipients()method 
public function setRecipients(recipients:Array):GameRequestContentBuilder

An array of user IDs, usernames or invite tokens of people to send request. If this is not specified, a friend selector will be displayed and the user can select up to 50 friends. This is equivalent to the "to" parameter when using the web game request dialog.

Parameters

recipients:Array — the list of user ids to send the request to

Returns
GameRequestContentBuilderGameRequestContentBuilder instance for chaining calls
setTitle()method 
public function setTitle(title:String):GameRequestContentBuilder

Sets an optional title for the dialog; maximum length is 50 characters.

Parameters

title:String — the title

Returns
GameRequestContentBuilderGameRequestContentBuilder instance for chaining calls
Constant Detail
TAGConstant
public static const TAG:String = GameRequestContentBuilder