made createTableView static method, now it controlls creating tableView.