[ Index ]

PHP Cross Reference of Joomla 4.2.2 documentation

title

Body

[close]

/administrator/components/com_installer/src/Model/ -> DatabaseModel.php (summary)

(no description)

Copyright: (C) 2011 Open Source Matters, Inc.
License: GNU General Public License version 2 or later; see LICENSE.txt
File Size: 666 lines (22 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

DatabaseModel:: (16 methods):
  __construct()
  getErrorCount()
  fetchSchemaCache()
  populateState()
  fix()
  getItems()
  getListQuery()
  mergeSchemaCache()
  getSchemaVersion()
  fixSchemaVersion()
  compareUpdateVersion()
  getOtherInformationMessage()
  getErrorsMessage()
  fixUpdateVersion()
  getDefaultTextFilters()
  fixDefaultTextFilters()


Class: DatabaseModel  - X-Ref

Installer Database Model

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

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

getErrorCount()   X-Ref
Method to return the total number of errors in all the extensions, saved in cache.

return: integer

fetchSchemaCache($cid = 0)   X-Ref
Method to populate the schema cache.

param: integer  $cid  The extension ID to get the schema for
return: void

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

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

fix($cids = array()   X-Ref
Fixes database problems.

param: array  $cids  List of the selected extensions to fix
return: void|boolean

getItems()   X-Ref
Gets the changeset array.

return: array  Array with the information of the versions problems, errors and the extensions itself

getListQuery()   X-Ref
Method to get the database query

return: DatabaseQuery  The database query

mergeSchemaCache($results)   X-Ref
Merge the items that will be visible with the changeSet information in cache

param: array  $results  extensions returned from parent::getItems().
return: array  the changeSetList of the merged items

getSchemaVersion($extensionId)   X-Ref
Get version from #__schemas table.

param: integer  $extensionId  id of the extensions.
return: mixed  the return value from the query, or null if the query fails.

fixSchemaVersion($changeSet, $extensionId)   X-Ref
Fix schema version if wrong.

param: ChangeSet  $changeSet    Schema change set.
param: integer    $extensionId  ID of the extensions.
return: mixed  string schema version if success, false if fail.

compareUpdateVersion($extension)   X-Ref
Get current version from #__extensions table.

param: object  $extension  data from #__extensions of a single extension.
return: mixed  string message with the errors with the update version or null if none

getOtherInformationMessage($status)   X-Ref
Get a message of the tables skipped and checked

param: array  $status  status of of the update files
return: array  Messages with the errors with the update version

getErrorsMessage($errors)   X-Ref
Get a message with all errors found in a given extension

param: array  $errors  data from #__extensions of a single extension.
return: array  List of messages with the errors in the database

fixUpdateVersion($extensionId)   X-Ref
Fix Joomla version in #__extensions table if wrong (doesn't equal \JVersion short version).

param: integer  $extensionId  id of the extension
return: mixed  string update version if success, false if fail.

getDefaultTextFilters()   X-Ref
For version 2.5.x only
Check if com_config parameters are blank.

return: string  default text filters (if any).

fixDefaultTextFilters()   X-Ref
For version 2.5.x only
Check if com_config parameters are blank. If so, populate with com_content text filters.

return: void



Generated: Wed Sep 7 05:41:13 2022 Chilli.vc Blog - For Webmaster,Blog-Writer,System Admin and Domainer