Stack.PHP
A simple and easy to use PHP library for the Stack Exchange API.
Public Member Functions | List of all members
TagRequest Class Reference

A request for tags. More...

Inheritance diagram for TagRequest:
PagedRequest

Public Member Functions

 __construct ($url)
 Constructor for a tag request. More...
 
 Info ()
 Returns information about the current set of tags. More...
 
 ModeratorOnly ()
 Returns only moderator-only tags. More...
 
 Related ()
 Returns tags related to the current set of tags. More...
 
 Required ()
 Returns only the required tags. More...
 
 Synonyms ()
 Returns all of the tag synonyms. More...
 
 TopAnswerers ($period)
 Returns the top answerers for a given period. More...
 
 TopAnswers ()
 Returns the top answers a user has posted with the provided tags. More...
 
 TopAskers ($period)
 Returns the top askers for a given period. More...
 
 TopQuestions ()
 Returns the top questions a user has asked with the provided tags. More...
 
 Wikis ()
 Returns tag wikis for the current set of tags. More...
 
 SortByPopular ()
 Causes tags to be sorted according to their popularity. More...
 
- Public Member Functions inherited from PagedRequest
 __construct ($url, $return_object, $category=null, $method=null)
 Constructor for a paged request. More...
 
 Exec ()
 Performs the HTTP request. More...
 
 ID ($id)
 Adds the provided ID(s) to the request. More...
 
 Tag ($tag)
 Adds the provided tags to the request. More...
 
 FromDate ($date)
 Ensures that only items created after the specified date are returned in the response. More...
 
 ToDate ($date)
 Ensures that only items created before the specified date are returned in the response. More...
 
 Min ($minimum)
 Sets the minimum value for the range of the current sort. More...
 
 Max ($maximum)
 Sets the maximum value for the range of the current sort. More...
 
 Filter ($filter, $pagination_filter=null)
 Sets the specified filter for the request. More...
 
 URL ()
 Returns the URL constructed from this request. More...
 
 Ascending ()
 Causes the items to be returned in ascending order. More...
 
 Descending ()
 Causes the items to be returned in descending order. More...
 
 InName ($name)
 Returns only the items that contain the specified text in their names. More...
 
 SortBy ($method)
 Sort the results by the provided sort method. More...
 
 SortByActivity ()
 Orders the returned items by activity. More...
 
 SortByCreation ()
 Orders the returned items by creation date. More...
 
 SortByName ()
 Orders the returned items by their name. More...
 
 SortByVotes ()
 Orders the returned items by their score. More...
 

Additional Inherited Members

- Protected Attributes inherited from PagedRequest
 $url
 The URL that will be modified as methods are called.
 

Detailed Description

A request for tags.

Constructor & Destructor Documentation

◆ __construct()

TagRequest::__construct (   $url)

Constructor for a tag request.

Parameters
$urlthe domain name of the site or a URL object

Member Function Documentation

◆ Info()

TagRequest::Info ( )

Returns information about the current set of tags.

Returns
the current instance

◆ ModeratorOnly()

TagRequest::ModeratorOnly ( )

Returns only moderator-only tags.

Returns
the current instance

◆ Related()

TagRequest::Related ( )

Returns tags related to the current set of tags.

Returns
the current instance

◆ Required()

TagRequest::Required ( )

Returns only the required tags.

Returns
the current instance

◆ SortByPopular()

TagRequest::SortByPopular ( )

Causes tags to be sorted according to their popularity.

Returns
the current instance

◆ Synonyms()

TagRequest::Synonyms ( )

Returns all of the tag synonyms.

Returns
a TagSynonymRequest object

◆ TopAnswerers()

TagRequest::TopAnswerers (   $period)

Returns the top answerers for a given period.

Parameters
$periodone of Period::AllTime or Period::Month
Returns
a PagedRequest object

◆ TopAnswers()

TagRequest::TopAnswers ( )

Returns the top answers a user has posted with the provided tags.

Returns
a PagedRequest object

◆ TopAskers()

TagRequest::TopAskers (   $period)

Returns the top askers for a given period.

Parameters
$periodone of Period::AllTime or Period::Month
Returns
a PagedRequest object

◆ TopQuestions()

TagRequest::TopQuestions ( )

Returns the top questions a user has asked with the provided tags.

Returns
a QuestionRequest object

◆ Wikis()

TagRequest::Wikis ( )

Returns tag wikis for the current set of tags.

Returns
a PagedRequest object

The documentation for this class was generated from the following file: