Академический Документы
Профессиональный Документы
Культура Документы
by
Department of Computing & Mathematics
Waterford Institute of Technology
http://www.wit.ie
Android & Retrofit
A type-safe HTTP client for Android & Java
Android & Retrofit 3
Agenda & Goals
qInvestigate the use of Retrofit in App Development
qBe aware of the different Retrofit Annotations and Classes
and how, when and where to use them
qRevisit Java interfaces
qUnderstand how to integrate Retrofit into an Android App
qRefactor our CoffeeMate Case Study
http://instructure.github.io/blog/2013/12/09/volley-vs-retrofit/
OkHttpClient for
communication timeouts
(optional)
Retrofit.Builder to
create an instance of our
interface
Note the
Callback
interface
enqueue() allows
for asynchronous
callback to our service
Anonymous Callbacks
multiple calls here
Standard Callback