Skip to content
klazuka edited this page Sep 13, 2010 · 2 revisions

As a client of the Kal component, you only need to be concerned with 1 protocol and 1 class:

The KalDataSource protocol

98% of the work that you need to do to integrate Kal with your app will be done here in your KalDataSource implementation. The KalDataSource API allows your app to asynchronously fetch application data every time that the user switches between months. This API also provides synchronous methods that allow Kal to query your dataSource once the data has been loaded.

The KalViewController

In order to display the Kal component in your app, you must instantiate a KalViewController with your KalDataSource implementation and add the view controller to your app’s view hierarchy (either by directly attaching its view to a UIWindow or, the more common case, pushing it onto a UINavigationController or assigning it to a tab in your UITabViewController).

Kal was designed to provide all of the functionality found in Apple’s native calendar app’s month view. In general, there should be no need to subclass KalViewController. If, however, your app needs calendar functionality that diverges from Apple’s implementation, then you will probably need to subclass KalViewController or, more likely, fork the Kal source code.