function drupal_static_reset

7.x bootstrap.inc drupal_static_reset($name = NULL)
8.x bootstrap.inc drupal_static_reset($name = NULL)

Resets one or all centrally stored static variable(s).

Parameters

$name: Name of the static variable to reset. Omit to reset all variables. Resetting all variables should only be used, for example, for running unit tests with a clean environment.

107 calls to drupal_static_reset()
block_page_build in drupal/modules/block/block.module
Implements hook_page_build().
book_node_delete in drupal/modules/book/book.module
Implements hook_node_delete().
BootstrapGetFilenameTestCase::testDrupalGetFilename in drupal/modules/simpletest/tests/bootstrap.test
Test that drupal_get_filename() works correctly when the file is not found in the database.
BootstrapIPAddressTestCase::setUp in drupal/modules/simpletest/tests/bootstrap.test
Sets up a Drupal site for running functional and integration tests.
BootstrapIPAddressTestCase::tearDown in drupal/modules/simpletest/tests/bootstrap.test
Delete created files and temporary files directory, delete the tables created by setUp(), and reset the database prefix.

... See full list

File

drupal/includes/bootstrap.inc, line 3392
Functions that need to be loaded on every Drupal request.

Code

function drupal_static_reset($name = NULL) {
  drupal_static($name, NULL, TRUE);
}