Display Logs for the Objective-C JMS Client
In this procedure, you will learn how to gather data on your Kaazing Gateway Objective-C JMS client.
Before You Begin
This procedure is part of Checklist: Build Objective-C (iOS) JMS Clients Using Kaazing Gateway, that includes the following steps:
- Use the Objective-C JMS Client API
- Secure Your Objective-C Client
- Troubleshoot Your Objective-C JMS Client
- Display Logs for the Objective-C JMS Client
Note: Learn about supported browsers, operating systems, and platform versions in the Release Notes.
To Display Logs for the Objective-C JMS Client
- Build your Objective-C JMS client, as described in Build Objective-C (iOS) JMS Clients.
Add the following line into one of the existing functions, such as
viewDidLoad()
:KMTracerDebug = YES;
For example:
- (void)viewDidLoad { subscribeButton.enabled = NO; subscribeButton.alpha = 0.5f; sendButton.enabled = NO; sendButton.alpha = 0.5f; logView.editable = NO; [super viewDidLoad]; KMTracerDebug = YES; }
Build your Xcode project, run the Objective-C client in the Xcode Simulator, and perform some actions for the Objective-C client to log.
The output is displayed in the Xcode Target Output area.:
Notes
- If you run the Objective-C client on an iOS device, the logging output is also displayed in Console for the device in Xcode Organizer. In Xcode, click Window, click Organizer, locate the iOS device in DEVICES, and click Console.
- See KMTracer for more information.