Version 1
[yaffs-website] / web / modules / contrib / crop / src / EntityProviderBase.php
diff --git a/web/modules/contrib/crop/src/EntityProviderBase.php b/web/modules/contrib/crop/src/EntityProviderBase.php
new file mode 100644 (file)
index 0000000..0a379a1
--- /dev/null
@@ -0,0 +1,25 @@
+<?php
+
+namespace Drupal\crop;
+
+use Drupal\Core\Entity\EntityInterface;
+use Drupal\Core\Plugin\PluginBase;
+
+/**
+ * Base implementation for entity provider plugins.
+ */
+abstract class EntityProviderBase extends PluginBase implements EntityProviderInterface {
+
+  /**
+   * {@inheritdoc}
+   */
+  public function label() {
+    $this->pluginDefinition['label'];
+  }
+
+  /**
+   * {@inheritdoc}
+   */
+  abstract public function uri(EntityInterface $entity);
+
+}