API reference

ChallengeOptions Class

The Challenge Option is a parameter that can be passed in the com.meta.horizon.platform.ovr.requests.Challenges#getList(ChallengeOptions challengeOptions, int limit) method to retrieve a list of challenges that match the specified options. The com.meta.horizon.platform.ovr.options.ChallengeOptions#ChallengeOptions() parameter allows you to specify the criteria for the challenges you want to retrieve, such as the viewer filter, the visibility, or the date range.

Constructors

ChallengeOptions ()
Signature
com.meta.horizon.platform.ovr.options.ChallengeOptions.ChallengeOptions()

Protected Methods

finalize ()
Signature
void com.meta.horizon.platform.ovr.options.ChallengeOptions.finalize()
Returns
void

Methods

getHandle ()
Signature
long com.meta.horizon.platform.ovr.options.ChallengeOptions.getHandle()
Returns
long
setDescription ( value )
The description of the challenge is a detailed and informative text that provides a comprehensive overview of the challenge's objectives, rules, and requirements, which can be retrieved with com.meta.horizon.platform.ovr.models.Challenge#getDescription().
Signature
ChallengeOptions com.meta.horizon.platform.ovr.options.ChallengeOptions.setDescription(String value)
Parameters
value: String
setEndDate ( value )
The challenge end date is the timestamp when this challenge ends, which can be retrieved using com.meta.horizon.platform.ovr.models.Challenge#getEndDate().
Signature
ChallengeOptions com.meta.horizon.platform.ovr.options.ChallengeOptions.setEndDate(LocalDateTime value)
Parameters
value: LocalDateTime
setIncludeActiveChallenges ( value )
This option indicates whether to include challenges that are currently active in the search results. By default, this is set to true, meaning that only active challenges will be returned.
Signature
ChallengeOptions com.meta.horizon.platform.ovr.options.ChallengeOptions.setIncludeActiveChallenges(boolean value)
Parameters
value: boolean
setIncludeFutureChallenges ( value )
This option indicates whether to include challenges that have not yet started in the search results. By default, this is set to false, meaning that only active will be returned.
Signature
ChallengeOptions com.meta.horizon.platform.ovr.options.ChallengeOptions.setIncludeFutureChallenges(boolean value)
Parameters
value: boolean
setIncludePastChallenges ( value )
This option indicates whether to include challenges that have already ended in the search results. By default, this is set to false, meaning that only active will be returned.
Signature
ChallengeOptions com.meta.horizon.platform.ovr.options.ChallengeOptions.setIncludePastChallenges(boolean value)
Parameters
value: boolean
setLeaderboardName ( value )
Optional: Only find challenges belonging to this leaderboard. This filter allows you to narrow down the search results to only include challenges that are associated with a specific leaderboard.
Signature
ChallengeOptions com.meta.horizon.platform.ovr.options.ChallengeOptions.setLeaderboardName(String value)
Parameters
value: String
setStartDate ( value )
The challenge start date is the timestamp when this challenge begins, which can be retrieved using com.meta.horizon.platform.ovr.models.Challenge#getStartDate().
Signature
ChallengeOptions com.meta.horizon.platform.ovr.options.ChallengeOptions.setStartDate(LocalDateTime value)
Parameters
value: LocalDateTime
setTitle ( value )
The title of the challenge is a descriptive label that provides a concise summary of the challenge's purpose and objectives, which can be retrieved with com.meta.horizon.platform.ovr.models.Challenge#getTitle().
Signature
ChallengeOptions com.meta.horizon.platform.ovr.options.ChallengeOptions.setTitle(String value)
Parameters
value: String
setViewerFilter ( value )
An enum that specifies what filter to apply to the list of returned challenges.
Returns all public (com.meta.horizon.platform.ovr.enums.ChallengeVisibility#Public) and invite-only (com.meta.horizon.platform.ovr.enums.ChallengeVisibility#InviteOnly) com.meta.horizon.platform.ovr.models.Challenge in which the user is a participant or invitee. Excludes private (com.meta.horizon.platform.ovr.enums.ChallengeVisibility#Private) challenges.
com.meta.horizon.platform.ovr.enums.ChallengeViewerFilter#Participating - Returns challenges the user is participating in.
com.meta.horizon.platform.ovr.enums.ChallengeViewerFilter#Invited - Returns challenges the user is invited to.
com.meta.horizon.platform.ovr.enums.ChallengeViewerFilter#ParticipatingOrInvited - Returns challenges the user is either participating in or invited to.
Signature
ChallengeOptions com.meta.horizon.platform.ovr.options.ChallengeOptions.setViewerFilter(ChallengeViewerFilter value)
Parameters
value: ChallengeViewerFilter
setVisibility ( value )
The challenge visibility setting specifies who can see and participate in this challenge, which be retrieved with com.meta.horizon.platform.ovr.models.Challenge#getVisibility(). There are three visibility levels: com.meta.horizon.platform.ovr.enums.ChallengeVisibility#Public, com.meta.horizon.platform.ovr.enums.ChallengeVisibility#InviteOnly and com.meta.horizon.platform.ovr.enums.ChallengeVisibility#Private.
Signature
ChallengeOptions com.meta.horizon.platform.ovr.options.ChallengeOptions.setVisibility(ChallengeVisibility value)
Parameters
value: ChallengeVisibility