Chapter 2. Mobile Messaging with STOMP
In this chapter, we will write our first messaging client: a native application running on an iPhone. We will use STOMP to send and receive messages using the Objective-C library StompKit.
In “Locations Application Using STOMP”, we described the Locations application. In this chapter, we will write the iOS application that broadcasts the device’s position and receives text messages (Figure 2-1).
Throughout the chapter, we will show all the code required to run the application.
The whole application code can be retrieved from the GitHub repository in the stomp/ios/ directory.
To use STOMP on iOS, we will use the StompKit Objective-C library that implements the STOMP protocol in a modern, event-driven way using ARC, Grand Central Dispatch, and blocks.
The source code of this library project is hosted on GitHub.
Create the Locations Project with Xcode
The application consists of a single view, so we choose the Single View Application ...