Package twitter4j.v1
Class StatusAdapter
java.lang.Object
twitter4j.v1.StatusAdapter
- All Implemented Interfaces:
StatusListener
,StreamListener
- Since:
- Twitter4J 2.1.3
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
onDeletionNotice
(StatusDeletionNotice statusDeletionNotice) Called upon deletionNotice notices.void
onException
(Exception ex) void
onScrubGeo
(long userId, long upToStatusId) Called upon location deletion messages.void
onStallWarning
(StallWarning warning) Called when receiving stall warnings.void
void
onTrackLimitationNotice
(int numberOfLimitedStatuses) This notice will be sent each time a limited stream becomes unlimited.
If this number is high and or rapidly increasing, it is an indication that your predicate is too broad, and you should consider a predicate with higher selectivity.
-
Constructor Details
-
StatusAdapter
public StatusAdapter()
-
-
Method Details
-
onStatus
- Specified by:
onStatus
in interfaceStatusListener
- Parameters:
status
- status
-
onDeletionNotice
Description copied from interface:StatusListener
Called upon deletionNotice notices. Clients are urged to honor deletionNotice requests and discard deleted statuses immediately. At times, status deletionNotice messages may arrive before the status. Even in this case, the late arriving status should be deleted from your backing store.- Specified by:
onDeletionNotice
in interfaceStatusListener
- Parameters:
statusDeletionNotice
- the deletionNotice notice- See Also:
-
onTrackLimitationNotice
public void onTrackLimitationNotice(int numberOfLimitedStatuses) Description copied from interface:StatusListener
This notice will be sent each time a limited stream becomes unlimited.
If this number is high and or rapidly increasing, it is an indication that your predicate is too broad, and you should consider a predicate with higher selectivity.- Specified by:
onTrackLimitationNotice
in interfaceStatusListener
- Parameters:
numberOfLimitedStatuses
- an enumeration of statuses that matched the track predicate but were administratively limited.- See Also:
-
onScrubGeo
public void onScrubGeo(long userId, long upToStatusId) Description copied from interface:StatusListener
Called upon location deletion messages. Clients are urged to honor deletion requests and remove appropriate geolocation information from both the display and your backing store immediately. Note that in some cases the location deletion message may arrive before a tweet that lies within the deletion range arrives. You should still strip the location data.- Specified by:
onScrubGeo
in interfaceStatusListener
- Parameters:
userId
- user idupToStatusId
- up to status id
-
onException
- Specified by:
onException
in interfaceStreamListener
- Parameters:
ex
- exception
-
onStallWarning
Description copied from interface:StatusListener
Called when receiving stall warnings.- Specified by:
onStallWarning
in interfaceStatusListener
- Parameters:
warning
- StallWaning- See Also:
-