From f2c047c63947cfb87c8eae4016c7bda40758dcfe Mon Sep 17 00:00:00 2001 From: Alex Pott Date: Sun, 27 Sep 2015 14:57:51 +0200 Subject: [PATCH] Issue #1912658 by joshi.rohit100, thsutton, mikebell_, zealfire, pjonckiere, dawehner: Document views access plugins --- .../Plugin/views/access/AccessPluginBase.php | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/core/modules/views/src/Plugin/views/access/AccessPluginBase.php b/core/modules/views/src/Plugin/views/access/AccessPluginBase.php index 57481fa7d1..58913649ef 100644 --- a/core/modules/views/src/Plugin/views/access/AccessPluginBase.php +++ b/core/modules/views/src/Plugin/views/access/AccessPluginBase.php @@ -29,6 +29,24 @@ /** * The base plugin to handle access control. + * + * Access plugins are responsible for controlling a user's access to the view. + * Views includes plugins for checking user roles and individual permissions. + * + * To define an access control plugin, extend this base class. Your access + * plugin should have an annotation that includes the plugin's metadata, for + * example: + * @Plugin( + * id = "denyall", + * title = @Translation("No Access"), + * help = @Translation("Will not be accessible.") + * ) + * The definition should include the following keys: + * - id: The unique identifier of your access plugin. + * - title: The human-readable name for your access plugin. + * - help: A short help message for your plugin. + * + * @see \Drupal\views\Plugin\ViewsPluginManager */ abstract class AccessPluginBase extends PluginBase { -- 2.22.2