Activity

The Daytime Client application has a single Activity, which presents a single Button and a TextView, as shown in figure 13.10.

When the Button is clicked, the Activity initiates the Daytime Server query and replaces the text of the TextView with the information received from the Daytime Server. Not much to it really, but that is fine, as all we are after in this sample is to demonstrate connectivity between the two applications. Listing 13.11 shows the onCreate method for this Activity.

Figure 13.10 The Daytime Client app
0 0

Post a comment