1 | <?php |
||
3 | class WPCOM_JSON_API_Get_Comments_Tree_Endpoint extends WPCOM_JSON_API_Endpoint { |
||
4 | /** |
||
5 | * Retrieves a list of comment data for a given site. |
||
6 | * |
||
7 | * @param {string} $status filter by status: 'all' | 'approved' | 'pending' | 'spam' | 'trash' |
||
|
|||
8 | * @param {int} $start_at first comment to search from going back in time |
||
9 | * @returns {array} list of comment information matching query |
||
10 | */ |
||
11 | public function get_site_tree( $status, $start_at = PHP_INT_MAX ) { |
||
37 | |||
38 | /** |
||
39 | * Retrieves a total count of comments for the given site. |
||
40 | * |
||
41 | * @param {string} $status filter by status: 'all' | 'approved' | 'pending' | 'spam' | 'trash' |
||
42 | * @returns {int} total count of comments for a site |
||
43 | */ |
||
44 | public function get_site_tree_total_count( $status ) { |
||
58 | |||
59 | /** |
||
60 | * Ensure a valid status is converted to a database-supported value if necessary. |
||
61 | * |
||
62 | * @param {string} $status 'all' | 'approved' | 'pending' | 'spam' | 'trash' |
||
63 | * @returns {string} value that exists in database |
||
64 | */ |
||
65 | public function get_comment_db_status( $status ) { |
||
74 | |||
75 | public function validate_status_param( $status ) { |
||
78 | |||
79 | // /sites/%s/comments-tree |
||
80 | function callback( $path = '', $blog_id = 0 ) { |
||
95 | } |
||
96 |
This check marks PHPDoc comments that could not be parsed by our parser. To see which comment annotations we can parse, please refer to our documentation on supported doc-types.