PHP Class app\http\controllers\TwitterController

Inheritance: extends Controller
Show file Open project: unicodeveloper/laravel-hackathon-starter Class Usage Examples

Protected Properties

Property Type Description
$searchItem string Item to be searched for, combing through twitter's massive data

Public Methods

Method Description
__construct ( ) Initialize the Controller with necessary arguments
getPage ( ) : mixed Return all tweets to the Twitter API dashboard
sendTweet ( Illuminate\Http\Request $request ) : string Post a tweet to the timeline

Private Methods

Method Description
getLatestTweets ( ) : Collection Get the latest tweets on a user timeline
searchForTweets ( string $item ) : Collection Search for tweets based on a search query

Method Details

__construct() public method

Initialize the Controller with necessary arguments
public __construct ( )

getPage() public method

Return all tweets to the Twitter API dashboard
public getPage ( ) : mixed
return mixed

sendTweet() public method

Post a tweet to the timeline
public sendTweet ( Illuminate\Http\Request $request ) : string
$request Illuminate\Http\Request
return string

Property Details

$searchItem protected property

Item to be searched for, combing through twitter's massive data
protected string $searchItem
return string