|
Moodle
2.2.1
http://www.collinsharper.com
|


Definition at line 45 of file Twitter.php.
| __construct | ( | array $ | options = null, |
| Zend_Oauth_Consumer $ | consumer = null |
||
| ) |
Constructor
| array | $options | Optional options array |
Definition at line 131 of file Twitter.php.

| __call | ( | $ | method, |
| $ | params | ||
| ) |
Method overloading
| string | $method | |
| array | $params |
| Zend_Service_Twitter_Exception | if unable to find method |
Reimplemented from Zend_Rest_Client.
Definition at line 243 of file Twitter.php.

| __get | ( | $ | type | ) |
Proxy service methods
| string | $type |
| Zend_Service_Twitter_Exception | If method not in method types list |
Definition at line 223 of file Twitter.php.
Performs an HTTP GET request to the $path.
| string | $path | |
| array | $query | Array of GET parameters |
| Zend_Http_Client_Exception |
Definition at line 990 of file Twitter.php.


| _init | ( | ) | [protected] |
Initialize HTTP authentication
Definition at line 274 of file Twitter.php.


| _performPost | ( | $ | method, |
| $ | data = null |
||
| ) | [protected] |
Perform a POST or PUT
Performs a POST or PUT request. Any data provided is set in the HTTP client. String data is pushed in as raw POST data; array or object data is pushed in as POST parameters.
| mixed | $method | |
| mixed | $data |
Reimplemented from Zend_Rest_Client.
Definition at line 1022 of file Twitter.php.

| _post | ( | $ | path, |
| $ | data = null |
||
| ) | [protected] |
Performs an HTTP POST request to $path.
| string | $path | |
| mixed | $data | Raw data to send |
| Zend_Http_Client_Exception |
Definition at line 1005 of file Twitter.php.


| _prepare | ( | $ | path | ) | [protected] |
Call a remote REST web service URI and return the Zend_Http_Response object
| string | $path | The path to append to the URI |
| Zend_Rest_Client_Exception |
Get the HTTP client and configure it for the endpoint URI. Do this each time because the Zend_Http_Client instance is shared among all Zend_Service_Abstract subclasses.
Definition at line 956 of file Twitter.php.

| _setDate | ( | $ | value | ) | [protected] |
Set date header
| int | string | $value |
Definition at line 302 of file Twitter.php.
| _validateScreenName | ( | $ | name | ) | [protected] |
Validate a screen name using Twitter rules
| string | $name |
| Zend_Service_Twitter_Exception |
Definition at line 937 of file Twitter.php.

| _validInteger | ( | $ | int | ) | [protected] |
Protected function to validate that the integer is valid or return a 0
| $int |
| Zend_Http_Client_Exception | if HTTP request fails or times out |
Definition at line 922 of file Twitter.php.

End current session
| Zend_Http_Client_Exception | if HTTP request fails or times out |
Definition at line 760 of file Twitter.php.

Returns the number of api requests you have left per hour.
| Zend_Http_Client_Exception | if HTTP request fails or times out |
Definition at line 773 of file Twitter.php.

Verify Account Credentials
| Zend_Http_Client_Exception | if HTTP request fails or times out |
Definition at line 747 of file Twitter.php.

| blockBlocking | ( | $ | page = 1, |
| $ | returnUserIds = false |
||
| ) |
Returns an array of user objects that the authenticating user is blocking
| integer | $page | Optional. Specifies the page number of the results beginning at 1. A single page contains 20 ids. |
| boolean | $returnUserIds | Optional. Returns only the userid's instead of the whole user object |
Definition at line 904 of file Twitter.php.

| blockCreate | ( | $ | id | ) |
Blocks the user specified in the ID parameter as the authenticating user. Destroys a friendship to the blocked user if it exists.
| integer | string | $id | The ID or screen name of a user to block. |
Definition at line 850 of file Twitter.php.

| blockDestroy | ( | $ | id | ) |
Un-blocks the user specified in the ID parameter for the authenticating user
| integer | string | $id | The ID or screen_name of the user to un-block. |
Definition at line 864 of file Twitter.php.

| blockExists | ( | $ | id, |
| $ | returnResult = false |
||
| ) |
Returns if the authenticating user is blocking a target user.
| string | integer | $id | The ID or screen_name of the potentially blocked user. |
| boolean | $returnResult | Instead of returning a boolean return the rest response from twitter |
Definition at line 879 of file Twitter.php.

| directMessageDestroy | ( | $ | id | ) |
Destroy a direct message
| int | $id | ID of message to destroy |
| Zend_Http_Client_Exception | if HTTP request fails or times out |
Definition at line 687 of file Twitter.php.

| directMessageMessages | ( | array $ | params = array() | ) |
Retrieve direct messages for the current user
$params may include one or more of the following keys
| array | $params |
| Zend_Http_Client_Exception | if HTTP request fails or times out |
Definition at line 599 of file Twitter.php.

| directMessageNew | ( | $ | user, |
| $ | text | ||
| ) |
Send a direct message to a user
| int | string | $user | User to whom to send message |
| string | $text | Message to send to user |
| Zend_Service_Twitter_Exception | if message is too short or too long |
| Zend_Http_Client_Exception | if HTTP request fails or times out |
Definition at line 661 of file Twitter.php.

| directMessageSent | ( | array $ | params = array() | ) |
Retrieve list of direct messages sent by current user
$params may include one or more of the following keys
| array | $params |
| Zend_Http_Client_Exception | if HTTP request fails or times out |
Definition at line 631 of file Twitter.php.

| favoriteCreate | ( | $ | id | ) |
Mark a status as a favorite
| int | $id | Status ID you want to mark as a favorite |
| Zend_Http_Client_Exception | if HTTP request fails or times out |
Definition at line 820 of file Twitter.php.

| favoriteDestroy | ( | $ | id | ) |
Remove a favorite
| int | $id | Status ID you want to de-list as a favorite |
| Zend_Http_Client_Exception | if HTTP request fails or times out |
Definition at line 835 of file Twitter.php.

| favoriteFavorites | ( | array $ | params = array() | ) |
Fetch favorites
$params may contain one or more of the following:
| array | $params |
| Zend_Http_Client_Exception | if HTTP request fails or times out |
Definition at line 791 of file Twitter.php.

| friendshipCreate | ( | $ | id | ) |
Create friendship
| int | string | $id | User ID or name of new friend |
| Zend_Http_Client_Exception | if HTTP request fails or times out |
Definition at line 702 of file Twitter.php.

| friendshipDestroy | ( | $ | id | ) |
Destroy friendship
| int | string | $id | User ID or name of friend to remove |
| Zend_Http_Client_Exception | if HTTP request fails or times out |
Definition at line 717 of file Twitter.php.

| friendshipExists | ( | $ | id | ) |
Friendship exists
| int | string | $id | User ID or name of friend to see if they are your friend |
| Zend_Http_Client_Exception | if HTTP request fails or times out |
Definition at line 732 of file Twitter.php.

Get the local HTTP client as distinct from the static HTTP client inherited from Zend_Rest_Client
Definition at line 176 of file Twitter.php.

| getUsername | ( | ) |
Retrieve username
Definition at line 199 of file Twitter.php.

| isAuthorised | ( | ) |
Checks for an authorised state
Definition at line 186 of file Twitter.php.


| setLocalHttpClient | ( | Zend_Http_Client $ | client | ) |
Set local HTTP client as distinct from the static HTTP client as inherited from Zend_Rest_Client.
| Zend_Http_Client | $client |
Definition at line 163 of file Twitter.php.


| setUsername | ( | $ | value | ) |
Set username
| string | $value |
Definition at line 210 of file Twitter.php.

| statusDestroy | ( | $ | id | ) |
Destroy a status message
| int | $id | ID of status to destroy |
| Zend_Http_Client_Exception | if HTTP request fails or times out |
Definition at line 516 of file Twitter.php.

| statusFriendsTimeline | ( | array $ | params = array() | ) |
Friend Timeline Status
$params may include one or more of the following keys
| array | $params |
| Zend_Http_Client_Exception | if HTTP request fails or times out |
Definition at line 339 of file Twitter.php.

Public Timeline status
| Zend_Http_Client_Exception | if HTTP request fails or times out |
Definition at line 318 of file Twitter.php.

| statusReplies | ( | array $ | params = array() | ) |
Get status replies
$params may include one or more of the following keys
| Zend_Http_Client_Exception | if HTTP request fails or times out |
Definition at line 488 of file Twitter.php.

| statusShow | ( | $ | id | ) |
Show a single status
| int | $id | Id of status to show |
| Zend_Http_Client_Exception | if HTTP request fails or times out |
Definition at line 435 of file Twitter.php.

| statusUpdate | ( | $ | status, |
| $ | inReplyToStatusId = null |
||
| ) |
Update user's current status
| string | $status | |
| int | $in_reply_to_status_id |
| Zend_Http_Client_Exception | if HTTP request fails or times out |
| Zend_Service_Twitter_Exception | if message is too short or too long |
Definition at line 452 of file Twitter.php.

| statusUserTimeline | ( | array $ | params = array() | ) |
User Timeline status
$params may include one or more of the following keys
| Zend_Http_Client_Exception | if HTTP request fails or times out |
Definition at line 385 of file Twitter.php.

| userFollowers | ( | $ | lite = false | ) |
User Followers
| bool | $lite | If true, prevents inline inclusion of current status for followers; defaults to false |
| Zend_Http_Client_Exception | if HTTP request fails or times out |
Definition at line 562 of file Twitter.php.

| userFriends | ( | array $ | params = array() | ) |
User friends
| int | string | $id | Id or username of user for whom to fetch friends |
| Zend_Http_Client_Exception | if HTTP request fails or times out |
Definition at line 531 of file Twitter.php.

| userShow | ( | $ | id | ) |
Show extended information on a user
| int | string | $id | User ID or name |
| Zend_Http_Client_Exception | if HTTP request fails or times out |
Definition at line 580 of file Twitter.php.

$_cookieJar [protected] |
Definition at line 66 of file Twitter.php.
$_dateFormat = 'D, d M Y H:i:s T' [protected] |
Definition at line 73 of file Twitter.php.
$_localHttpClient = null [protected] |
Definition at line 123 of file Twitter.php.
$_methodType [protected] |
Definition at line 87 of file Twitter.php.
$_methodTypes [protected] |
array( 'status', 'user', 'directMessage', 'friendship', 'account', 'favorite', 'block' )
Definition at line 101 of file Twitter.php.
$_oauthConsumer = null [protected] |
Definition at line 94 of file Twitter.php.
$_options = array() [protected] |
Definition at line 116 of file Twitter.php.
$_username [protected] |
Definition at line 80 of file Twitter.php.
| const OAUTH_BASE_URI = 'http://twitter.com/oauth' |
OAuth Endpoint
Definition at line 61 of file Twitter.php.
| const STATUS_MAX_CHARACTERS = 246 |
246 is the current limit for a status message, 140 characters are displayed initially, with the remainder linked from the web UI or client. The limit is applied to a html encoded UTF-8 string (i.e. entities are counted in the limit which may appear unusual but is a security measure).
This should be reviewed in the future...
Definition at line 56 of file Twitter.php.