Inherits from TKViewController : UIViewController
Conforms to UISearchBarDelegate
UISearchDisplayDelegate
UITableViewDataSource
UITableViewDelegate
Declared in TKTableViewController.h

Overview

This class provides basic UITableViewController functionality under the TKViewController class.

The key differences between TKTableViewController and UITableViewController: – The UITableView is a subview of the base view. – The content offset of the UITableView is remembered if the view is ever deconstructed by a memory warning. – Built to easily allocate and handle an empty view and search functionality.

Tasks

Other Methods

Properties

  •   tableView

    Returns the table view managed by the controller object.

    property
  •   style

    Returns the table view style.

    property
  •   emptyView

    Returns the empty view. Good for displaying when the content of the table view is empty.

    property
  •   searchBar

    Returns a UISearchBar view.

    property
  •   searchBarDisplayController

    Returns a UISearchDisplayController for the search bar and table view.

    property
  •   clearsSelectionOnViewWillAppear

    The default value of this property is YES. When YES, the table view controller clears the table’s current selection when it receives a viewWillAppear: message. Setting this property to NO preserves the selection.

    property

Properties

clearsSelectionOnViewWillAppear

The default value of this property is YES. When YES, the table view controller clears the table’s current selection when it receives a viewWillAppear: message. Setting this property to NO preserves the selection.

@property (nonatomic, assign) BOOL clearsSelectionOnViewWillAppear

Discussion

The default value of this property is YES. When YES, the table view controller clears the table’s current selection when it receives a viewWillAppear: message. Setting this property to NO preserves the selection.

Declared In

TKTableViewController.h

emptyView

Returns the empty view. Good for displaying when the content of the table view is empty.

@property (nonatomic, strong) TKEmptyView *emptyView

Discussion

Returns the empty view. Good for displaying when the content of the table view is empty.

Declared In

TKTableViewController.h

searchBar

Returns a UISearchBar view.

@property (nonatomic, strong) UISearchBar *searchBar

Discussion

Returns a UISearchBar view.

Declared In

TKTableViewController.h

searchBarDisplayController

Returns a UISearchDisplayController for the search bar and table view.

@property (nonatomic, strong) UISearchDisplayController *searchBarDisplayController

Discussion

Returns a UISearchDisplayController for the search bar and table view.

Declared In

TKTableViewController.h

style

Returns the table view style.

@property (nonatomic, readonly) UITableViewStyle style

Discussion

Returns the table view style.

Declared In

TKTableViewController.h

tableView

Returns the table view managed by the controller object.

@property (nonatomic, strong) UITableView *tableView

Discussion

Returns the table view managed by the controller object.

Declared In

TKTableViewController.h

Instance Methods

initWithStyle:

Initializes a table-view controller to manage a table view of a given style.

- (id)initWithStyle:(UITableViewStyle)style

Parameters

style

A constant that specifies the style of table view that the controller object is to manage (UITableViewStylePlain or UITableViewStyleGrouped).

Return Value

An initialized TKTableViewController object or nil if the object couldn’t be created.

Discussion

Initializes a table-view controller to manage a table view of a given style.

Declared In

TKTableViewController.h