adriens / BeachCagouBot

Bot twitter pour les eaux de baignades de Nouméa
0 stars 0 forks source link

Put localization in tweets #28

Open adriens opened 5 years ago

adriens commented 5 years ago

Localize tweets to make it smarter.

adriens commented 5 years ago

See https://github.com/Twitter4J/Twitter4J/issues/317

adriens commented 5 years ago

See code sample below :

Twitter twitter = TwitterFactory.getSingleton();
StatusUpdate tweet = new StatusUpdate("Hey! I'm tweeting from the Stonehenge!");
GeoLocation stonehenge = new GeoLocation(51.1789, -1.8262);
tweet.setLocation(stonehenge);
twitter.updateStatus(latestStatus);