DateElementBase::datetimeRangeYears

protected static DateElementBase::datetimeRangeYears($string, $date = NULL) Specifies the start and end year to use as a date range. Handles a string like -3:+3 or 2001:2010 to describe a dynamic range of minimum and maximum years to use in a date selector. Centers the range around the current year, if any, but expands it far enough so it will pick up the year value in the field in case the value in the field is outside the initial range. Parameters string $string: A min and max year string li

forum_node_update

forum_node_update(EntityInterface $node) Implements hook_ENTITY_TYPE_update() for node entities. File core/modules/forum/forum.module, line 171 Provides discussion forums. Code function forum_node_update(EntityInterface $node) { if (\Drupal::service('forum_manager')->checkNodeType($node)) { // If this is not a new revision and does exist, update the forum record, // otherwise insert a new one. /** @var \Drupal\forum\ForumIndexStorageInterface $forum_index_storage */ $foru

search_cron

search_cron() Implements hook_cron(). Fires updateIndex() in the plugins for all indexable active search pages, and cleans up dirty words. See also search_dirty() File core/modules/search/search.module, line 187 Enables site-wide keyword searching. Code function search_cron() { // We register a shutdown function to ensure that search_total is always up // to date. drupal_register_shutdown_function('search_update_totals'); /** @var $search_page_repository \Drupal\search\SearchPageRep

ViewUI::unsetThirdPartySetting

public ViewUI::unsetThirdPartySetting($module, $key) Unsets a third-party setting. Parameters string $module: The module providing the third-party setting. string $key: The setting name. Return value mixed The value. Overrides ThirdPartySettingsInterface::unsetThirdPartySetting File core/modules/views_ui/src/ViewUI.php, line 1290 Class ViewUI Stores UI related temporary settings. Namespace Drupal\views_ui Code public function unsetThirdPartySetting($module, $key) { return $this->

FileTransfer::__get

FileTransfer::__get($name) Implements the magic __get() method. If the connection isn't set to anything, this will call the connect() method and return the result; afterwards, the connection will be returned directly without using this method. Parameters string $name: The name of the variable to return. Return value string|bool The variable specified in $name. File core/lib/Drupal/Core/FileTransfer/FileTransfer.php, line 93 Class FileTransfer Defines the base FileTransfer class. Namesp

Url::toRenderArray

public Url::toRenderArray() Returns the route information for a render array. Return value array An associative array suitable for a render array. File core/lib/Drupal/Core/Url.php, line 744 Class Url Defines an object that holds information about a URL. Namespace Drupal\Core Code public function toRenderArray() { $render_array = [ '#url' => $this, '#options' => $this->getOptions(), ]; if (!$this->unrouted) { $render_array['#access_callback'] = [get_class

LanguageAddForm::actions

public LanguageAddForm::actions(array $form, FormStateInterface $form_state) Returns an array of supported actions for the current entity form. @todo Consider introducing a 'preview' action here, since it is used by many entity types. Overrides EntityForm::actions File core/modules/language/src/Form/LanguageAddForm.php, line 102 Class LanguageAddForm Controller for language addition forms. Namespace Drupal\language\Form Code public function actions(array $form, FormStateInterface $form

QueryBase::orConditionGroup

public QueryBase::orConditionGroup() Creates a new group of conditions ORed together. For example, consider a map entity with an 'attributes' field containing 'building_type' and 'color' columns. To find all green and red bikesheds: $query = \Drupal::entityQuery('map'); $group = $query->orConditionGroup() ->condition('attributes.color', 'red') ->condition('attributes.color', 'green'); $entity_ids = $query ->condition('attributes.building_type', 'bikeshed') ->

Url::toUriString

public Url::toUriString() Generates a URI string that represents the data in the Url object. The URI will typically have the scheme of route: even if the object was constructed using an entity: or internal: scheme. A internal: URI that does not match a Drupal route with be returned here with the base: scheme, and external URLs will be returned in their original form. Return value string A URI representation of the Url object data. File core/lib/Drupal/Core/Url.php, line 511 Class Url Defi

AccessArgumentsResolverFactoryInterface::getArgumentsResolver

public AccessArgumentsResolverFactoryInterface::getArgumentsResolver(RouteMatchInterface $route_match, AccountInterface $account, Request $request = NULL) Returns the arguments resolver to use when running access checks. Parameters \Drupal\Core\Routing\RouteMatchInterface $route_match: The route match object to be checked. \Drupal\Core\Session\AccountInterface $account: The account being checked. \Symfony\Component\HttpFoundation\Request $request: Optional, the request object. Return value \D