#import <OFScoreEnumerator.h>
List of all members.
Detailed Description
OFScoreEnumerator objects provide a convenient way to enumerate the scores for a particular leaderboard.
Enumeration works by downloading one 'page' at a time. A page is simply a fixed-size array of scores.
- See also:
- OFScoreEnumeratorDelegate
-
OFLeaderboard
Member Function Documentation
- (void) jumpToPage: |
|
(NSInteger) |
page |
|
Retrieve a given page of scores. The page index is a one-based value such that page == 1 refers to the first page.
- Note:
- Invokes -(void)didReceiveScoresOFScoreEnumerator: on success, -(void)didFailReceiveScoresOFScoreEnumerator: on failure.
Retrieve the next page of scores.
- Returns:
YES
if the next page is being downloaded, NO
if the current page is already the last page.
- Note:
- Invokes -(void)didReceiveScoresOFScoreEnumerator: on success, -(void)didFailReceiveScoresOFScoreEnumerator: on failure.
- (void) pageWithCurrentUser |
|
|
|
Retrieve the page of scores that contains the current user's score.
- Note:
- Invokes -(void)didReceiveScoresOFScoreEnumerator: on success, -(void)didFailReceiveScoresOFScoreEnumerator: on failure.
Retrieve the previous page of scores.
- Returns:
YES
if the previous page is being downloaded, NO
if the current page is already the first page.
- Note:
- Invokes -(void)didReceiveScoresOFScoreEnumerator: on success, -(void)didFailReceiveScoresOFScoreEnumerator: on failure.
Returns an initialized score enumerator which will enumerate a set of scores of a given leaderboard based on a filter. The enumerator object will immediately fetch the first page of scores, but they will not be available when this method returns. One of the following delegate methods will be called to when the asynchronous server response has been received. The first page of scores is passed as a parameter to the success delegate.
- Note:
- Invokes -(void)didReceiveScoresOFScoreEnumerator: on success, -(void)didFailReceiveScoresOFScoreEnumerator: on failure.
- Parameters:
-
leaderboard | The leaderboard to enumerator over |
pageSize | Number of scores contained in each page |
filter | The filter to use when getting the scores |
- Returns:
- An initialized OFScoreEnumerator object.
Member Data Documentation
Property Documentation
- (NSInteger) currentPage [read, assign] |
The current page of scores contained in the scores property.
- Note:
- Page numbers are 1-based.
- (BOOL) hasScores [read, assign] |
YES
if the enumerator has a valid set of scores, NO
otherwise
- (BOOL) isCurrentUserPage [read, assign] |
YES
if the current page of scores contains the current user's score, NO
otherwise
- (NSInteger) pageSize [read, assign] |
The number of scores requested at one time.
- (NSArray *) scores [read, assign] |
The current page of scores. The score objects contained in the array are instances of the OFHighScore class.
- (NSInteger) totalPages [read, assign] |
The total number of pages of scores that are enumerable.
- Note:
- Page numbers are 1-based.
The documentation for this class was generated from the following file: