Skip to content
This repository has been archived by the owner on Apr 7, 2022. It is now read-only.

Can not get RawJson in using Twitter4jStatusClient #56

Closed
tsdeng opened this issue Apr 24, 2013 · 1 comment
Closed

Can not get RawJson in using Twitter4jStatusClient #56

tsdeng opened this issue Apr 24, 2013 · 1 comment

Comments

@tsdeng
Copy link

tsdeng commented Apr 24, 2013

Hi, I'm trying to switch from twitter4j to hbc-twitter4j.
I found that in hbc-twitter4j StatusListener#onStatus, I can not get the rawjson by calling
DataObjectFactory.getRawJSON(status)

But in the original twitter4j, I can set the configuration to save the rawjson with each tweet object by:
ConfigurationBuilder.setJSONStoreEnabled(true);

In hbc-twitter4j, I can't find a way to set this and therefore will get "null" when calling DataObjectFactory.getRawJSON(status)

@kevinoliver
Copy link
Contributor

I'm not an expert on Twitter4J, but as far as I can tell, DataObjectFactory.getRawJSON is somewhat of an implementation detail of t4j and its sensitive to which thread calls it.

If you need the raw json, you can use hbc-core, or maybe you could create a subclass of BaseTwitter4JClient and override preprocessMessage() or one of the other methods to do the necessary work in there?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

No branches or pull requests

2 participants