Programming for Ubiquitous Things
Lab Guide 5 - Spring 2024
Remote Invocation
Objective:
- Understand the Remote Invocation of a Remote Web Server
In the previous lab classes, we covered the main aspects related to the implementation of a stand-alone Android application. By stand-alone, we mean that the application provides its functionality without requiring any access to the network. In this lab class, the focus is to build an application that accesses a web server.
The application to be built must invoke a web server (see next section for suggestions of the server to be invoked). For that purpose, the application should use the volley library:
- go to the web page https://developer.android.com/training/volley and follow the steps in order to send a simple GET request to a web server.
The application must have a button on its main screen that, when clicked, sends the request mentioned above. The first 1000 lines of the data in the response must be shown (no need to interpret it) in the application screen using a “Toast”. The application should also display (e.g., with a “Toast”) which site is being accessed and if the remote invocation was successful.
To test the application, you can use the following web addresses:
· - https://www.norwegian.com/en
· - /english/
You can/should also test the application with other web addresses.