summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNathaniel Catchpole2017-07-28 16:33:41 +0900
committerNathaniel Catchpole2017-07-28 16:33:41 +0900
commitb77f378db7000da5c67b4d0792c77e7fb964c2bf (patch)
tree6094e2831402327e4ad6ef46963f7e3374919214
parent9586b37b0780e34b62c86860dd0f19ec624bb643 (diff)
Issue #2876419 by Sam152, timmillwood, plach: Review content_moderation module and mark code with @internal where necessary
-rw-r--r--core/modules/content_moderation/src/ContentModerationStateInterface.php2
-rw-r--r--core/modules/content_moderation/src/ContentPreprocess.php2
-rw-r--r--core/modules/content_moderation/src/Entity/ContentModerationState.php5
-rw-r--r--core/modules/content_moderation/src/EntityOperations.php2
-rw-r--r--core/modules/content_moderation/src/EntityTypeInfo.php2
-rw-r--r--core/modules/content_moderation/src/Permissions.php2
-rw-r--r--core/modules/content_moderation/src/RevisionTracker.php2
-rw-r--r--core/modules/content_moderation/src/RevisionTrackerInterface.php2
-rw-r--r--core/modules/content_moderation/src/Routing/EntityModerationRouteProvider.php2
-rw-r--r--core/modules/content_moderation/src/ViewsData.php2
10 files changed, 23 insertions, 0 deletions
diff --git a/core/modules/content_moderation/src/ContentModerationStateInterface.php b/core/modules/content_moderation/src/ContentModerationStateInterface.php
index 5b7ee2e..679ab9e 100644
--- a/core/modules/content_moderation/src/ContentModerationStateInterface.php
+++ b/core/modules/content_moderation/src/ContentModerationStateInterface.php
@@ -10,6 +10,8 @@ use Drupal\user\EntityOwnerInterface;
*
* Content moderation state entities track the moderation state of other content
* entities.
+ *
+ * @internal
*/
interface ContentModerationStateInterface extends ContentEntityInterface, EntityOwnerInterface {
diff --git a/core/modules/content_moderation/src/ContentPreprocess.php b/core/modules/content_moderation/src/ContentPreprocess.php
index 77fcd78..e986d8f 100644
--- a/core/modules/content_moderation/src/ContentPreprocess.php
+++ b/core/modules/content_moderation/src/ContentPreprocess.php
@@ -9,6 +9,8 @@ use Symfony\Component\DependencyInjection\ContainerInterface;
/**
* Determines whether a route is the "Latest version" tab of a node.
+ *
+ * @internal
*/
class ContentPreprocess implements ContainerInjectionInterface {
diff --git a/core/modules/content_moderation/src/Entity/ContentModerationState.php b/core/modules/content_moderation/src/Entity/ContentModerationState.php
index 5b1c250..39b0ff4 100644
--- a/core/modules/content_moderation/src/Entity/ContentModerationState.php
+++ b/core/modules/content_moderation/src/Entity/ContentModerationState.php
@@ -39,6 +39,11 @@ use Drupal\user\UserInterface;
* "langcode" = "langcode",
* }
* )
+ *
+ * @internal
+ * This entity is marked internal because it should not be used directly to
+ * alter the moderation state of an entity. Instead, the computed
+ * moderation_state field should be set on the entity directly.
*/
class ContentModerationState extends ContentEntityBase implements ContentModerationStateInterface {
diff --git a/core/modules/content_moderation/src/EntityOperations.php b/core/modules/content_moderation/src/EntityOperations.php
index 38ec7cd..e04d7db 100644
--- a/core/modules/content_moderation/src/EntityOperations.php
+++ b/core/modules/content_moderation/src/EntityOperations.php
@@ -14,6 +14,8 @@ use Symfony\Component\DependencyInjection\ContainerInterface;
/**
* Defines a class for reacting to entity events.
+ *
+ * @internal
*/
class EntityOperations implements ContainerInjectionInterface {
diff --git a/core/modules/content_moderation/src/EntityTypeInfo.php b/core/modules/content_moderation/src/EntityTypeInfo.php
index eb8a6b7..b6b77ae 100644
--- a/core/modules/content_moderation/src/EntityTypeInfo.php
+++ b/core/modules/content_moderation/src/EntityTypeInfo.php
@@ -26,6 +26,8 @@ use Symfony\Component\DependencyInjection\ContainerInterface;
*
* This class contains primarily bridged hooks for compile-time or
* cache-clear-time hooks. Runtime hooks should be placed in EntityOperations.
+ *
+ * @internal
*/
class EntityTypeInfo implements ContainerInjectionInterface {
diff --git a/core/modules/content_moderation/src/Permissions.php b/core/modules/content_moderation/src/Permissions.php
index efa6849..ddd841a 100644
--- a/core/modules/content_moderation/src/Permissions.php
+++ b/core/modules/content_moderation/src/Permissions.php
@@ -7,6 +7,8 @@ use Drupal\workflows\Entity\Workflow;
/**
* Defines a class for dynamic permissions based on transitions.
+ *
+ * @internal
*/
class Permissions {
diff --git a/core/modules/content_moderation/src/RevisionTracker.php b/core/modules/content_moderation/src/RevisionTracker.php
index 2011237..3f82fdd 100644
--- a/core/modules/content_moderation/src/RevisionTracker.php
+++ b/core/modules/content_moderation/src/RevisionTracker.php
@@ -8,6 +8,8 @@ use Drupal\Core\Database\SchemaObjectExistsException;
/**
* Tracks metadata about revisions across entities.
+ *
+ * @internal
*/
class RevisionTracker implements RevisionTrackerInterface {
diff --git a/core/modules/content_moderation/src/RevisionTrackerInterface.php b/core/modules/content_moderation/src/RevisionTrackerInterface.php
index 2b7cf95..5079151 100644
--- a/core/modules/content_moderation/src/RevisionTrackerInterface.php
+++ b/core/modules/content_moderation/src/RevisionTrackerInterface.php
@@ -4,6 +4,8 @@ namespace Drupal\content_moderation;
/**
* Tracks metadata about revisions across content entities.
+ *
+ * @internal
*/
interface RevisionTrackerInterface {
diff --git a/core/modules/content_moderation/src/Routing/EntityModerationRouteProvider.php b/core/modules/content_moderation/src/Routing/EntityModerationRouteProvider.php
index e96f374..67ca4fb 100644
--- a/core/modules/content_moderation/src/Routing/EntityModerationRouteProvider.php
+++ b/core/modules/content_moderation/src/Routing/EntityModerationRouteProvider.php
@@ -17,6 +17,8 @@ use Symfony\Component\Routing\RouteCollection;
* Provides the following routes:
* - The latest version tab, showing the latest revision of an entity, not the
* default one.
+ *
+ * @internal
*/
class EntityModerationRouteProvider implements EntityRouteProviderInterface, EntityHandlerInterface {
diff --git a/core/modules/content_moderation/src/ViewsData.php b/core/modules/content_moderation/src/ViewsData.php
index dbef193..189562d 100644
--- a/core/modules/content_moderation/src/ViewsData.php
+++ b/core/modules/content_moderation/src/ViewsData.php
@@ -8,6 +8,8 @@ use Drupal\Core\StringTranslation\StringTranslationTrait;
/**
* Provides the content_moderation views integration.
+ *
+ * @internal
*/
class ViewsData {