\Horde_Ajax_Application_TwitterHandler

Defines the AJAX actions used in the Twitter client.

Summary

Methods
Properties
Constants
twitterUpdate()
retweet()
favorite()
unfavorite()
updateStatus()
No public properties found
No constants found
_getTwitterObject()
_buildTweet()
_doTwitterGetPage()
_twitterError()
No protected properties found
N/A
No private methods found
No private properties found
N/A

Methods

twitterUpdate()

twitterUpdate() : array

Update the twitter timeline.

Returns

array —

An hash containing the following keys:

  • o: The id of the oldest tweet
  • n: The id of the newest tweet
  • c: The HTML content

retweet()

retweet() : string

Retweet a tweet. Expects the following in $this->vars: - tweetId: The tweet id to retweet.

  • i:

Returns

string —

The HTML to render the newly retweeted tweet.

favorite()

favorite() : \stdClass

Favorite a tweet. Expects: - tweetId:

Returns

\stdClass

unfavorite()

unfavorite() 

Unfavorite a tweet. Expects: - tweetId:

updateStatus()

updateStatus() : string

Update twitter status. Expects: - inReplyTo: - statusText:

Returns

string —

The HTML text of the new tweet.

_getTwitterObject()

_getTwitterObject() : \Horde_Service_Twitter

Returns

\Horde_Service_Twitter

_buildTweet()

_buildTweet(\stdClass  $tweet) : \Horde_View

Helper method to build a view object for a tweet.

Parameters

\stdClass $tweet

The tweet object.

Returns

\Horde_View —

The view object, populated with tweet data.

_doTwitterGetPage()

_doTwitterGetPage() : \[type]

Helper method for getting a slice of tweets.

Expects the following in $this->vars:

  • max_id:
  • since_id:
  • i:
  • mentions:

Returns

\[type] —

[description]

_twitterError()

_twitterError(  $e) 

Parameters

$e