[ Index ]

PHP Cross Reference of Joomla 2.5.4 DE

title

Body

[close]

/libraries/joomla/application/component/ -> modellist.php (summary)

(no description)

Copyright: Copyright (C) 2005 - 2012 Open Source Matters, Inc. All rights reserved.
License: GNU General Public License version 2 or later; see LICENSE
File Size: 373 lines (10 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

JModelList:: (10 methods):
  __construct()
  _getListQuery()
  getItems()
  getListQuery()
  getPagination()
  getStoreId()
  getTotal()
  getStart()
  populateState()
  getUserStateFromRequest()


Class: JModelList  - X-Ref

Model class for handling lists of items.

__construct($config = array()   X-Ref
Constructor.

param: array  $config  An optional associative array of configuration settings.

_getListQuery()   X-Ref
Method to cache the last query constructed.

This method ensures that the query is constructed only once for a given state of the model.

return: JDatabaseQuery  A JDatabaseQuery object

getItems()   X-Ref
Method to get an array of data items.

return: mixed  An array of data items on success, false on failure.

getListQuery()   X-Ref
Method to get a JDatabaseQuery object for retrieving the data set from a database.

return: JDatabaseQuery   A JDatabaseQuery object to retrieve the data set.

getPagination()   X-Ref
Method to get a JPagination object for the data set.

return: JPagination  A JPagination object for the data set.

getStoreId($id = '')   X-Ref
Method to get a store id based on the model configuration state.

This is necessary because the model is used by the component and
different modules that might need different sets of data or different
ordering requirements.

param: string  $id  An identifier string to generate the store id.
return: string  A store id.

getTotal()   X-Ref
Method to get the total number of items for the data set.

return: integer  The total number of items available in the data set.

getStart()   X-Ref
Method to get the starting number of items for the data set.

return: integer  The starting number of items available in the data set.

populateState($ordering = null, $direction = null)   X-Ref
Method to auto-populate the model state.

This method should only be called once per instantiation and is designed
to be called on the first call to the getState() method unless the model
configuration flag to ignore the request is set.

Note. Calling getState in this method will result in recursion.

param: string  $ordering   An optional ordering field.
param: string  $direction  An optional direction (asc|desc).
return: void

getUserStateFromRequest($key, $request, $default = null, $type = 'none', $resetPage = true)   X-Ref
Gets the value of a user state variable and sets it in the session

This is the same as the method in JApplication except that this also can optionally
force you back to the first page when a filter has changed

param: string   $key        The key of the user state variable.
param: string   $request    The name of the variable passed in a request.
param: string   $default    The default value for the variable if not found. Optional.
param: string   $type       Filter for the variable, for valid values see {@link JFilterInput::clean()}. Optional.
param: boolean  $resetPage  If true, the limitstart in request is set to zero
return: The request user state.



Generated: Tue Apr 3 11:40:28 2012 Cross-referenced by PHPXref 0.7.1