Issue #3268818 by ravi.shankar, quietone: Fix class comment doc blocks in non tests 'Drupal.Commenting.DocComment.ShortSingleLine'

(cherry picked from commit eec3210128)
merge-requests/1961/merge
Alex Pott 2022-11-29 12:13:59 +00:00
parent 2301594474
commit f8144f44e2
No known key found for this signature in database
GPG Key ID: BDA67E7EE836E5CE
42 changed files with 102 additions and 75 deletions

View File

@ -11,10 +11,11 @@ use Drupal\Composer\Generator\PackageGenerator;
use Symfony\Component\Finder\Finder;
/**
* Provides static functions for composer script events. See also
* core/lib/Drupal/Composer/Composer.php, which contains similar
* scripts needed by projects that include drupal/core. Scripts that
* are only needed by drupal/drupal go here.
* Provides static functions for composer script events.
*
* See also core/lib/Drupal/Composer/Composer.php, which contains similar
* scripts needed by projects that include drupal/core. Scripts that are only
* needed by drupal/drupal go here.
*
* @see https://getcomposer.org/doc/articles/scripts.md
*/

View File

@ -3,8 +3,7 @@
namespace Drupal\Component\Plugin\Discovery;
/**
* An interface defining the minimum requirements of building a plugin
* discovery component.
* Defines the minimum requirements for a plugin discovery component.
*
* @ingroup plugin_api
*/

View File

@ -3,8 +3,7 @@
namespace Drupal\Component\Plugin\Discovery;
/**
* A discovery mechanism that allows plugin definitions to be manually
* registered rather than actively discovered.
* Allows plugin definitions to be manually registered.
*/
class StaticDiscovery implements DiscoveryInterface {

View File

@ -3,7 +3,6 @@
namespace Drupal\Component\Plugin\Exception;
/**
* Exception thrown when a decorator's _call() method is triggered, but the
* decorated object does not contain the requested method.
* Thrown when a decorator's _call() method uses a method that does not exist.
*/
class InvalidDecoratedMethod extends \BadMethodCallException implements ExceptionInterface {}

View File

@ -3,7 +3,6 @@
namespace Drupal\Component\Plugin\Exception;
/**
* Generic Plugin exception class to be thrown when no more specific class
* is applicable.
* Base class for plugin exceptions.
*/
class PluginException extends \Exception implements ExceptionInterface {}

View File

@ -3,9 +3,11 @@
namespace Drupal\Core\Ajax;
/**
* AJAX command for updating the value of a hidden form_build_id input element
* on a form. It requires the form passed in to have keys for both the old build
* ID in #build_id_old and the new build ID in #build_id.
* Ajax command for updating the form build ID.
*
* Used for updating the value of a hidden form_build_id input element on a
* form. It requires the form passed in to have keys for both the old build ID
* in #build_id_old and the new build ID in #build_id.
*
* The primary use case for this Ajax command is to serve a new build ID to a
* form served from the cache to an anonymous user, preventing one anonymous

View File

@ -3,8 +3,7 @@
namespace Drupal\Core\DependencyInjection;
/**
* Provides an interface to get an instance of a class with dependency
* injection.
* Provides interface to get an instance of a class with dependency injection.
*/
interface ClassResolverInterface {

View File

@ -6,8 +6,9 @@ use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface;
/**
* Adds services tagged "needs_destruction" to the "kernel_destruct_subscriber"
* service.
* Adds services with specific tags to "kernel_destruct_subscriber" service.
*
* Only services tagged with "needs_destruction" are added.
*
* @see \Drupal\Core\DestructableInterface
*/

View File

@ -3,8 +3,7 @@
namespace Drupal\Core\DependencyInjection;
/**
* Exception thrown when a method is called that requires a container, but the
* container is not initialized yet.
* Exception, thrown when a method is called on a non-initialized container.
*
* @see \Drupal
*/

View File

@ -13,8 +13,10 @@ use Symfony\Component\Validator\ConstraintViolationList;
use Symfony\Component\Validator\ConstraintViolationListInterface;
/**
* Configuration entity that contains widget options for all components of an
* entity form in a given form mode.
* Configuration entity.
*
* Contains widget options for all components of an entity form in a given
* form mode.
*
* @ConfigEntityType(
* id = "entity_form_display",

View File

@ -12,8 +12,10 @@ use Drupal\Core\Render\Element;
use Drupal\Core\TypedData\TranslatableInterface as TranslatableDataInterface;
/**
* Configuration entity that contains display options for all components of a
* rendered entity in a given view mode.
* Configuration entity.
*
* Contains display options for all components of a rendered entity in a given
* view mode.
*
* @ConfigEntityType(
* id = "entity_view_display",

View File

@ -5,8 +5,9 @@ namespace Drupal\Core\Lock;
use Drupal\Core\Database\Connection;
/**
* Defines the persistent database lock backend. This backend is global for this
* Drupal installation.
* Defines the persistent database lock backend.
*
* This backend is global for this Drupal installation.
*
* @ingroup lock
*/

View File

@ -3,8 +3,7 @@
namespace Drupal\Core\Password;
/**
* Secure password hashing functions based on the Portable PHP password
* hashing framework.
* Secure hashing functions based on Portable PHP password hashing framework.
*
* @see http://www.openwall.com/phpass/
*/

View File

@ -6,8 +6,10 @@ use Drupal\Component\Plugin\Derivative\DeriverInterface;
use Symfony\Component\DependencyInjection\ContainerInterface;
/**
* Provides additional plugin definitions based on an existing definition using
* service injection.
* Creates additional plugin definitions.
*
* The created definitions are based on an existing definition using service
* injection.
*/
interface ContainerDeriverInterface extends DeriverInterface {

View File

@ -3,8 +3,9 @@
namespace Drupal\Core\Queue;
/**
* Defines a batch queue handler used by the Batch API for non-progressive
* batches.
* Defines a batch queue handler.
*
* Used by the Batch API for non-progressive batches.
*
* This implementation:
* - Ensures FIFO ordering.

View File

@ -3,6 +3,8 @@
namespace Drupal\Core\Queue;
/**
* Queue garbage collection interface.
*
* If the Drupal 'queue' service implements this interface, the
* garbageCollection() method will be called during cron.
*

View File

@ -5,8 +5,9 @@ namespace Drupal\Core\Updater;
use Drupal\Core\Url;
/**
* Defines a class for updating modules using
* Drupal\Core\FileTransfer\FileTransfer classes via authorize.php.
* Defines a class for updating modules.
*
* Uses Drupal\Core\FileTransfer\FileTransfer classes via authorize.php.
*/
class Module extends Updater implements UpdaterInterface {

View File

@ -5,8 +5,9 @@ namespace Drupal\Core\Updater;
use Drupal\Core\Url;
/**
* Defines a class for updating themes using
* Drupal\Core\FileTransfer\FileTransfer classes via authorize.php.
* Defines a class for updating themes.
*
* Uses Drupal\Core\FileTransfer\FileTransfer classes via authorize.php.
*/
class Theme extends Updater implements UpdaterInterface {

View File

@ -3,8 +3,7 @@
namespace Drupal\Core\Updater;
/**
* Defines an Exception class for the Drupal\Core\Updater\Updater class
* hierarchy.
* Defines an Exception class for Drupal\Core\Updater\Updater class hierarchy.
*
* This is identical to the base Exception class, we just give it a more
* specific name so that call sites that want to tell the difference can

View File

@ -3,8 +3,9 @@
namespace Drupal\Core\Updater;
/**
* Defines a child class of Drupal\Core\Updater\UpdaterException that indicates
* a Drupal\Core\FileTransfer\FileTransfer exception.
* Defines a child class of Drupal\Core\Updater\UpdaterException.
*
* Indicates a Drupal\Core\FileTransfer\FileTransfer exception.
*
* We have to catch Drupal\Core\FileTransfer\FileTransfer exceptions
* and wrap those in t(), since Drupal\Core\FileTransfer\FileTransfer

View File

@ -8,8 +8,10 @@ use Drupal\Core\StringTranslation\StringTranslationTrait;
use Drupal\Core\StringTranslation\TranslationInterface;
/**
* Prevents book module from being uninstalled whilst any book nodes exist or
* there are any book outline stored.
* Prevents book module from being uninstalled under certain conditions.
*
* These conditions are when any book nodes exist or there are any book outline
* stored.
*/
class BookUninstallValidator implements ModuleUninstallValidatorInterface {

View File

@ -7,8 +7,9 @@ use Drupal\views\Plugin\views\argument\ArgumentPluginBase;
use Symfony\Component\DependencyInjection\ContainerInterface;
/**
* Argument handler to accept a user id to check for nodes that
* user posted or commented on.
* The views user ID argument handler.
*
* Accepts a user ID to check for nodes that the user posted or commented on.
*
* @ingroup views_argument_handlers
*

View File

@ -6,8 +6,7 @@ use Drupal\Core\Database\Database;
use Drupal\views\Plugin\views\filter\FilterPluginBase;
/**
* Filter handler to accept a user id to check for nodes that user posted or
* commented on.
* Filter handler, accepts user ID to check for nodes user posted/commented on.
*
* @ingroup views_filter_handlers
*

View File

@ -5,8 +5,7 @@ namespace Drupal\comment\Plugin\views\sort;
use Drupal\views\Plugin\views\sort\SortPluginBase;
/**
* Sort handler to sort by last comment name which might be in 2 different
* fields.
* Sort handler, sorts by last comment name which can be in 2 different fields.
*
* @ingroup views_sort_handlers
*

View File

@ -10,8 +10,10 @@ use Drupal\Core\StringTranslation\TranslationInterface;
use Drupal\taxonomy\VocabularyInterface;
/**
* Prevents forum module from being uninstalled whilst any forum nodes exist
* or there are any terms in the forum vocabulary.
* Prevents forum module from being uninstalled under certain conditions.
*
* These conditions are when any forum nodes exist or there are any terms in the
* forum vocabulary.
*/
class ForumUninstallValidator implements ModuleUninstallValidatorInterface {

View File

@ -8,6 +8,8 @@ use Drupal\migrate\Plugin\migrate\destination\EntityConfigBase;
use Drupal\migrate\Row;
/**
* Entity image style destination.
*
* Every migration that uses this destination must have an optional
* dependency on the d6_file migration to ensure it runs first.
*

View File

@ -6,8 +6,7 @@ use Drupal\language\LanguageNegotiationMethodBase;
use Symfony\Component\HttpFoundation\Request;
/**
* Class that determines the language to be assigned to URLs when none is
* detected.
* Determines the language to be assigned to URLs when none is detected.
*
* The language negotiation process has a fallback chain that ends with the
* default language negotiation method. Each built-in language type has a

View File

@ -11,7 +11,9 @@ use Drupal\layout_builder\OverridesSectionStorageInterface;
use Symfony\Component\EventDispatcher\EventSubscriberInterface;
/**
* An event subscriber to prepare section storage via the
* An event subscriber to prepare section storage.
*
* Section storage works via the
* \Drupal\layout_builder\Event\PrepareLayoutEvent.
*
* @see \Drupal\layout_builder\Event\PrepareLayoutEvent

View File

@ -5,8 +5,9 @@ namespace Drupal\migrate_drupal\Plugin\migrate\source\d7;
use Drupal\migrate_drupal\Plugin\migrate\source\DrupalSqlBase;
/**
* Base class for D7 source plugins which need to collect field values from
* the Field API.
* Base class for D7 source plugins which need to collect field values.
*
* Field values are collected from the Field API.
*
* Refer to the existing implementations for examples:
* @see \Drupal\node\Plugin\migrate\source\d7\Node

View File

@ -5,8 +5,9 @@ namespace Drupal\node\Plugin\views\argument;
use Drupal\user\Plugin\views\argument\Uid;
/**
* Filter handler to accept a user id to check for nodes that
* user posted or created a revision on.
* Filter handler, accepts a user ID.
*
* Checks for nodes that a user posted or created a revision on.
*
* @ViewsArgument("node_uid_revision")
*/

View File

@ -5,8 +5,7 @@ namespace Drupal\node\Plugin\views\row;
use Drupal\views\Plugin\views\row\RssPluginBase;
/**
* Plugin which performs a node_view on the resulting object
* and formats it as an RSS item.
* Performs a node_view on the resulting object and formats it as an RSS item.
*
* @ViewsRow(
* id = "node_rss",

View File

@ -10,8 +10,7 @@ use Drupal\views\Plugin\views\display\DisplayPluginBase;
use Drupal\views\Plugin\views\argument\NumericArgument;
/**
* Argument handler for list field to show the human readable name in the
* summary.
* Argument handler for list field to show human readable name in the summary.
*
* @ingroup views_argument_handlers
*

View File

@ -8,6 +8,8 @@ use Drupal\Core\Session\AccountInterface;
use Symfony\Component\Routing\Route;
/**
* Permission access check.
*
* Determines access to routes based on permissions defined via
* $module.permissions.yml files.
*/

View File

@ -5,6 +5,8 @@ namespace Drupal\views;
use Drupal\Core\Extension\ModuleHandlerInterface;
/**
* View analyzer plugin manager.
*
* This tool is a small plugin manager to perform analysis on a view and
* report results to the user. This tool is meant to let modules that
* provide data to Views also help users properly use that data by

View File

@ -8,6 +8,8 @@ use Drupal\views\Plugin\views\display\DisplayPluginBase;
use Drupal\views\ManyToOneHelper;
/**
* Argument handler for many to one relationships.
*
* An argument handler for use in fields that have a many to one relationship
* with the table(s) to the left. This adds a bunch of options that are
* reasonably common with this type of relationship.
@ -92,8 +94,7 @@ class ManyToOne extends ArgumentPluginBase {
}
/**
* Override ensureMyTable so we can control how this joins in.
* The operator actually has influence over joining.
* {@inheritdoc}
*/
public function ensureMyTable() {
$this->helper->ensureMyTable();

View File

@ -6,8 +6,9 @@ use Drupal\Core\Form\FormStateInterface;
use Drupal\Core\Plugin\Context\ContextDefinition;
/**
* Basic argument handler for arguments that are numeric. Incorporates
* break_phrase.
* Basic argument handler for arguments that are numeric.
*
* Incorporates break_phrase.
*
* @ingroup views_argument_handlers
*

View File

@ -10,6 +10,8 @@ use Drupal\views\Plugin\views\display\DisplayPluginBase;
use Drupal\views\ManyToOneHelper;
/**
* Argument handler for string.
*
* Basic argument handler to implement string arguments that may have length
* limits.
*

View File

@ -7,8 +7,7 @@ use Drupal\views\ResultRow;
use Drupal\views\ViewExecutable;
/**
* A handler to run a field through check_markup, using a companion
* format field.
* Handler to run a field through check_markup, using a companion format field.
*
* - format: (REQUIRED) Either a string format id to use for this field or an
* array('field' => {$field}) where $field is the field in this table

View File

@ -8,8 +8,9 @@ use Drupal\views\Plugin\views\display\DisplayPluginBase;
use Drupal\views\ManyToOneHelper;
/**
* Complex filter to handle filtering for many to one relationships,
* such as terms (many terms per node) or roles (many roles per user).
* Complex filter to handle filtering for many to one relationships.
*
* Examples are terms (many terms per node) or roles (many roles per user).
*
* The construct method needs to be overridden to provide a list of options;
* alternately, the valueForm and adminSummary methods need to be overridden

View File

@ -7,8 +7,9 @@ use Drupal\Core\Form\FormStateInterface;
use Symfony\Component\DependencyInjection\ContainerInterface;
/**
* Basic textfield filter to handle string filtering commands
* including equality, like, not like, etc.
* Basic textfield filter to handle string filtering commands.
*
* Including equality, like, not like, etc.
*
* @ingroup views_filter_handlers
*

View File

@ -8,7 +8,9 @@ use Drupal\views\Views;
use Drupal\views\Entity\View;
/**
* Relationship handler that allows a groupwise maximum of the linked in table.
* The relationship handler for groupwise maximum queries.
*
* It allows a groupwise maximum of the linked in table.
* For a definition, see:
* http://dev.mysql.com/doc/refman/5.0/en/example-maximum-column-group-row.html
* In lay terms, instead of joining to get all matching records in the linked

View File

@ -3,8 +3,9 @@
namespace Drupal\views\Plugin\views\style;
/**
* Unformatted style plugin to render rows one after another with no
* decorations.
* Unformatted style plugin to render rows.
*
* Row are rendered one after another with no decorations.
*
* @ingroup views_style_plugins
*