public function StaticTest::access

Determine if the current user has access or not.

Parameters

\Drupal\Core\Session\AccountInterface $account: The user who wants to access this view.

Return value

TRUE Returns whether the user has access to the view.

Overrides AccessPluginBase::access

File

drupal/core/modules/views/tests/views_test_data/lib/Drupal/views_test_data/Plugin/views/access/StaticTest.php, line 34
Definition of Drupal\views_test_data\Plugin\views\access\StaticTest.

Class

StaticTest
Tests a static access plugin.

Namespace

Drupal\views_test_data\Plugin\views\access

Code

public function access(AccountInterface $account) {
  return !empty($this->options['access']);
}