forked from filip/streak_mirror
-
Notifications
You must be signed in to change notification settings - Fork 0
/
twitterStream.pde
28 lines (23 loc) · 912 Bytes
/
twitterStream.pde
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
/////////STREAM TWEETS
String imgUrl = null;
String imgPage = null;
void twitterStreams(){
twitterStream.addListener(listener);
twitterStream.filter(new FilterQuery().track(streamWords));
if (geoStream == true){
twitterStream.filter(new FilterQuery().locations(streamLocations));
}
}
StatusListener listener = new StatusListener() {
int count=0;
public void onStatus(Status status) {
println("Location: " + status.getGeoLocation());
println("Time: " + status.getCreatedAt());
println("@" + status.getUser().getScreenName() + ":" + status.getText());
}
public void onStallWarning(StallWarning stallWarning){}
public void onDeletionNotice(StatusDeletionNotice statusDeletionNotice) {}
public void onTrackLimitationNotice(int numberOfLimitedStatuses) {}
public void onScrubGeo(long userId, long upToStatusId) {}
public void onException(Exception ex) {}
};