[ Index ]

PHP Cross Reference of Joomla 4.2.2 documentation

title

Body

[close]

/administrator/components/com_finder/src/Indexer/ -> Adapter.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: 918 lines (26 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 27 functions

  __construct()
  onStartIndex()
  onBeforeIndex()
  onBuildIndex()
  onFinderGarbageCollection()
  change()
  reindex()
  remove()
  categoryAccessChange()
  categoryStateChange()
  checkCategoryAccess()
  checkItemAccess()
  getContentCount()
  getItem()
  getItems()
  getListQuery()
  getPluginType()
  getStateQuery()
  getUpdateQueryByTime()
  getUpdateQueryByIds()
  getTypeId()
  getUrl()
  getItemMenuTitle()
  itemAccessChange()
  itemStateChange()
  pluginDisable()
  translateState()

Functions
Functions that are not part of a class:

__construct(&$subject, $config)   X-Ref
Method to instantiate the indexer adapter.

param: object  $subject  The object to observe.
param: array   $config   An array that holds the plugin configuration.

onStartIndex()   X-Ref
Method to get the adapter state and push it into the indexer.

return: void

onBeforeIndex()   X-Ref
Method to prepare for the indexer to be run. This method will often
be used to include dependencies and things of that nature.

return: boolean  True on success.

onBuildIndex()   X-Ref
Method to index a batch of content items. This method can be called by
the indexer many times throughout the indexing process depending on how
much content is available for indexing. It is important to track the
progress correctly so we can display it to the user.

return: boolean  True on success.

onFinderGarbageCollection()   X-Ref
Method to remove outdated index entries

return: integer

change($id, $property, $value)   X-Ref
Method to change the value of a content item's property in the links
table. This is used to synchronize published and access states that
are changed when not editing an item directly.

param: string   $id        The ID of the item to change.
param: string   $property  The property that is being changed.
param: integer  $value     The new value of that property.
return: boolean  True on success.

reindex($id)   X-Ref
Method to reindex an item.

param: integer  $id  The ID of the item to reindex.
return: void

remove($id, $removeTaxonomies = true)   X-Ref
Method to remove an item from the index.

param: string  $id                The ID of the item to remove.
param: bool    $removeTaxonomies  Remove empty taxonomies
return: boolean  True on success.

categoryAccessChange($row)   X-Ref
Method to update index data on category access level changes

param: Table  $row  A Table object
return: void

categoryStateChange($pks, $value)   X-Ref
Method to update index data on category access level changes

param: array    $pks    A list of primary key ids of the content that has changed state.
param: integer  $value  The value of the state that the content has been changed to.
return: void

checkCategoryAccess($row)   X-Ref
Method to check the existing access level for categories

param: Table  $row  A Table object
return: void

checkItemAccess($row)   X-Ref
Method to check the existing access level for items

param: Table  $row  A Table object
return: void

getContentCount()   X-Ref
Method to get the number of content items available to index.

return: integer  The number of content items available to index.

getItem($id)   X-Ref
Method to get a content item to index.

param: integer  $id  The id of the content item.
return: Result  A Result object.

getItems($offset, $limit, $query = null)   X-Ref
Method to get a list of content items to index.

param: integer         $offset  The list offset.
param: integer         $limit   The list limit.
param: QueryInterface  $query   A QueryInterface object. [optional]
return: Result[]  An array of Result objects.

getListQuery($query = null)   X-Ref
Method to get the SQL query used to retrieve the list of content items.

param: mixed  $query  A QueryInterface object. [optional]
return: QueryInterface  A database object.

getPluginType($id)   X-Ref
Method to get the plugin type

param: integer  $id  The plugin ID
return: string  The plugin type

getStateQuery()   X-Ref
Method to get a SQL query to load the published and access states for
an article and category.

return: QueryInterface  A database object.

getUpdateQueryByTime($time)   X-Ref
Method to get the query clause for getting items to update by time.

param: string  $time  The modified timestamp.
return: QueryInterface  A database object.

getUpdateQueryByIds($ids)   X-Ref
Method to get the query clause for getting items to update by id.

param: array  $ids  The ids to load.
return: QueryInterface  A database object.

getTypeId()   X-Ref
Method to get the type id for the adapter content.

return: integer  The numeric type id for the content.

getUrl($id, $extension, $view)   X-Ref
Method to get the URL for the item. The URL is how we look up the link
in the Finder index.

param: integer  $id         The id of the item.
param: string   $extension  The extension the category is in.
param: string   $view       The view for the URL.
return: string  The URL of the item.

getItemMenuTitle($url)   X-Ref
Method to get the page title of any menu item that is linked to the
content item, if it exists and is set.

param: string  $url  The URL of the item.
return: mixed  The title on success, null if not found.

itemAccessChange($row)   X-Ref
Method to update index data on access level changes

param: Table  $row  A Table object
return: void

itemStateChange($pks, $value)   X-Ref
Method to update index data on published state changes

param: array    $pks    A list of primary key ids of the content that has changed state.
param: integer  $value  The value of the state that the content has been changed to.
return: void

pluginDisable($pks)   X-Ref
Method to update index data when a plugin is disabled

param: array  $pks  A list of primary key ids of the content that has changed state.
return: void

translateState($item, $category = null)   X-Ref
Method to translate the native content states into states that the
indexer can use.

param: integer  $item      The item state.
param: integer  $category  The category state. [optional]
return: integer  The translated indexer state.



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