FormBuilder::buildForm

public FormBuilder::buildForm($form_id, FormStateInterface &$form_state) Builds and processes a form for a given form ID. The form may also be retrieved from the cache if the form was built in a previous page load. The form is then passed on for processing, validation, and submission if there is proper input. Parameters \Drupal\Core\Form\FormInterface|string $form_id: The value must be one of the following: The name of a class that implements \Drupal\Core\Form\FormInterface. An instance of

hook_library_info_alter

hook_library_info_alter(&$libraries, $extension) Alter libraries provided by an extension. Allows modules and themes to change libraries' definitions; mostly used to update a library to a newer version, while ensuring backward compatibility. In general, such manipulations should only be done to extend the library's functionality in a backward-compatible way, to avoid breaking other modules and themes that may be using the library. Parameters array $libraries: An associative array of librar

LocalStream::dir_readdir

public LocalStream::dir_readdir() Support for readdir(). Return value string The next filename, or FALSE if there are no more files in the directory. Overrides PhpStreamWrapperInterface::dir_readdir See also http://php.net/manual/streamwrapper.dir-readdir.php File core/lib/Drupal/Core/StreamWrapper/LocalStream.php, line 536 Class LocalStream Defines a Drupal stream wrapper base class for local files. Namespace Drupal\Core\StreamWrapper Code public function dir_readdir() { return re

BlockListController::listing

public BlockListController::listing($theme = NULL, Request $request = NULL) Shows the block administration page. Parameters string|null $theme: Theme key of block list. \Symfony\Component\HttpFoundation\Request $request: The current request. Return value array A render array as expected by drupal_render(). Overrides EntityListController::listing File core/modules/block/src/Controller/BlockListController.php, line 53 Class BlockListController Defines a controller to list blocks. Namespa

ThemeRegistry

Builds the run-time theme registry. A cache collector to allow the theme registry to be accessed as a complete registry, while internally caching only the parts of the registry that are actually in use on the site. On cache misses the complete theme registry is loaded and used to update the run-time cache. Hierarchy class \Drupal\Core\Cache\CacheCollector implements CacheCollectorInterface, DestructableInterfaceclass \Drupal\Core\Utility\ThemeRegistry implements DestructableInterface File c

DbUpdateController

Controller routines for database update routes. Hierarchy class \Drupal\Core\Controller\ControllerBase implements ContainerInjectionInterface uses LoggerChannelTrait, LinkGeneratorTrait, RedirectDestinationTrait, UrlGeneratorTrait, StringTranslationTraitclass \Drupal\system\Controller\DbUpdateController File core/modules/system/src/Controller/DbUpdateController.php, line 22 Namespace Drupal\system\Controller Members Name Modifiers Type Description ControllerBase::$configFacto

ViewsData::cacheSet

protected ViewsData::cacheSet($cid, $data) Sets data to the cache backend. Parameters string $cid: The cache ID to set. mixed $data: The data that will be cached. File core/modules/views/src/ViewsData.php, line 210 Class ViewsData Class to manage and lazy load cached views data. Namespace Drupal\views Code protected function cacheSet($cid, $data) { return $this->cacheBackend->set($this->prepareCid($cid), $data, Cache::PERMANENT, array('views_data', 'config:core.extension'))

db_rename_table

db_rename_table($table, $new_name) Renames a table. Parameters $table: The current name of the table to be renamed. $new_name: The new name for the table. Deprecated as of Drupal 8.0.x, will be removed in Drupal 9.0.0. Instead, get a database connection injected into your service from the container, get its schema driver, and call renameTable() on it. For example, $injected_database->schema()->renameTable($table, $new_name); See also \Drupal\Core\Database\Schema::renameTable() Relate

ControllerBase

Utility base class for thin controllers. Controllers that use this base class have access to a number of utility methods and to the Container, which can greatly reduce boilerplate dependency handling code. However, it also makes the class considerably more difficult to unit test. Therefore this base class should only be used by controller classes that contain only trivial glue code. Controllers that contain sufficiently complex logic that it's worth testing should not use this base class but us

ContentEntityStorageBase::cleanIds

protected ContentEntityStorageBase::cleanIds(array $ids) Ensures integer entity IDs are valid. The identifier sanitization provided by this method has been introduced as Drupal used to rely on the database to facilitate this, which worked correctly with MySQL but led to errors with other DBMS such as PostgreSQL. Parameters array $ids: The entity IDs to verify. Return value array The sanitized list of entity IDs. File core/lib/Drupal/Core/Entity/ContentEntityStorageBase.php, line 561 Class