class EntityTestMulBundle

Same name and namespace in other branches
  1. 11.x core/modules/system/tests/modules/entity_test/src/Entity/EntityTestMulBundle.php \Drupal\entity_test\Entity\EntityTestMulBundle
  2. 10 core/modules/system/tests/modules/entity_test/src/Entity/EntityTestMulBundle.php \Drupal\entity_test\Entity\EntityTestMulBundle

Defines the Test entity mul bundle configuration entity.

Plugin annotation


@ConfigEntityType(
  id = "entity_test_mul_bundle",
  label = @Translation("Test entity multilingual bundle"),
  handlers = {
    "access" = "\Drupal\Core\Entity\EntityAccessControlHandler",
    "form" = {
      "default" = "\Drupal\Core\Entity\BundleEntityFormBase",
    },
    "route_provider" = {
      "html" = "Drupal\Core\Entity\Routing\DefaultHtmlRouteProvider",
    },
  },
  admin_permission = "administer entity_test_mul_with_bundle content",
  bundle_of = "entity_test_mul_with_bundle",
  entity_keys = {
    "id" = "id",
    "label" = "label"
  },
  config_export = {
    "id",
    "label",
    "description",
  },
  links = {
    "add-form" = "/entity_test_mul_bundle/add",
  }
)

Hierarchy

Expanded class hierarchy of EntityTestMulBundle

1 file declares its use of EntityTestMulBundle
ContentTranslationPermissionsTest.php in core/modules/content_translation/tests/src/Kernel/ContentTranslationPermissionsTest.php

File

core/modules/system/tests/modules/entity_test/src/Entity/EntityTestMulBundle.php, line 39

Namespace

Drupal\entity_test\Entity
View source
class EntityTestMulBundle extends ConfigEntityBundleBase implements EntityDescriptionInterface {
  
  /**
   * The machine name.
   *
   * @var string
   */
  protected $id;
  
  /**
   * The human-readable name.
   *
   * @var string
   */
  protected $label;
  
  /**
   * The description.
   *
   * @var string
   */
  protected $description;
  
  /**
   * {@inheritdoc}
   */
  public function getDescription() {
    return $this->description;
  }
  
  /**
   * {@inheritdoc}
   */
  public function setDescription($description) {
    $this->description = $description;
    return $this;
  }

}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.