The UI SDK ships with a view controller which you can use (and/or subclass) to display the catalog. If you wish you can also use them via storyboards, just remember to pass along the Catalog instance.
let catalogResultVC = CatalogResultViewController()
catalogResultVC.catalog = catalog
present(catalogResultVC, animated: true)
Should you require further customization, the UI SDK ships with a CatalogView that provides the basics of displaying two dimensional data.
CatalogQuery query = new CatalogQuery();
Traveler.fetchCatalog(query, new CatalogSearchCallback() {
@Override
public void onCatalogSearchSuccess(Catalog catalog) {
}
@Override
public void onCatalogSearchError(Error error) {
}
});
The UI SDK ships with a fragment to handle the display of the fetched Catalog. To include this fragment add a <FrameLayout> to your Activity's layout XML: