A Simple How To:
The first thing we need to do is to create an application within your twitter account, grant it access and generate authentication tokens (although, the consumer tokens will also work and it will be automatically generated upon creating the application).
1) Create an Application in your twitter account: Go To > Settings > Applications > Developers > “here”. You must login with your twitter account (or the account that you will use in your API).
2) Create your application: Enter required fields.
3) A consumer keys will be given to you. if you’re only looking to read status updates, this is sufficient enough for your needs.
For this example, I’m using Eclipse IDE.
1) Create a New Java Project and include the Twitter4j Library (download it here).
2) Create a class and check the code below:
And the Actual Twitter Feed:
Download the code :p
Get ready to program in a whole new way!
Functional Programming in Java will help you quickly get on top of the new, essential Java 8 language features and the functional style that will change and improve your code. This short, targeted book will help you make the paradigm shift from the old imperative way to a less error-prone, more elegant, and concise coding style that’s also a breeze to parallelize. You’ll explore the syntax and semantics of lambda expressions, method and constructor references, and functional interfaces. You’ll design and write applications better using the new standards in Java 8 and the JDK.