Back to Joomla project (class list)

Class TableInterface - list of methods

Table class interface.
Package: Joomla\CMS\Table
Copyright: (C) 2014 Open Source Matters, Inc.
License: GNU General Public License version 2 or later; see LICENSE.txt
Located at: Joomla/Table/TableInterface.php
Project: Joomla

Method Summary

public bool
(mixed $src, mixed $ignore = array())

Method to bind an associative array or object to the TableInterface instance.
Parameters
  • mixed $src An associative array or object to bind to the TableInterface instance.
  • mixed $ignore An optional array or space separated list of properties to ignore while binding.
Returns
  • bool True on success.
Since
  • 3.2
-
  • \UnexpectedValueException
Show source code of this method: bind Source Code

public bool
()

Method to perform sanity checks on the TableInterface instance properties to ensure they are safe to store in the database.
Returns
  • bool True if the instance is sane and able to be stored in the database.
Since
  • 3.2
Show source code of this method: check Source Code

public bool
(mixed $pk = null)

Method to delete a record.
Parameters
  • mixed $pk An optional primary key value to delete. If not set the instance property value is used.
Returns
  • bool True on success.
Since
  • 3.2
-
  • \UnexpectedValueException
Show source code of this method: delete Source Code

public \Joomla\Database\DatabaseDriver
()

Method to get the DatabaseDriver object.
Returns
  • \Joomla\Database\DatabaseDriver The internal database driver object.
Since
  • 3.2
Show source code of this method: getDbo Source Code

public string
()

Method to get the primary key field name for the table.
Returns
  • string The name of the primary key for the table.
Since
  • 3.2
Show source code of this method: getKeyName Source Code

public bool
(mixed $keys = null, mixed $reset = true)

Method to load a row from the database by primary key and bind the fields to the TableInterface instance properties.
Parameters
  • mixed $keys An optional primary key value to load the row by, or an array of fields to match. If not set the instance property value is used.
  • bool $reset True to reset the default values before loading the new row.
Returns
  • bool True if successful. False if row not found.
Since
  • 3.2
-
  • \RuntimeException
  • \UnexpectedValueException
Show source code of this method: load Source Code

public void
()

Method to reset class properties to the defaults set in the class definition.
Returns
  • void
Since
  • 3.2
Show source code of this method: reset Source Code

public bool
(mixed $updateNulls = false)

Method to store a row in the database from the TableInterface instance properties.
Parameters
  • bool $updateNulls True to update fields even if they are null.
Returns
  • bool True on success.
Since
  • 3.2
Show source code of this method: store Source Code

public mixed
()

Returns the identity (primary key) value of this record
Returns
  • mixed
Since
  • 4.0.0
Show source code of this method: getId Source Code

public bool
(mixed $key)

Check if the record has a property (applying a column alias if it exists)
Parameters
  • string $key key to be checked
Returns
  • bool
Since
  • 4.0.0
Show source code of this method: hasField Source Code

Tags Summary

Since
3.2