You are here

public function RelationRepositoryInterface::getAvailable in Relation 8.2

Same name and namespace in other branches
  1. 8 src/RelationRepositoryInterface.php \Drupal\relation\RelationRepositoryInterface::getAvailable()

Returns the relation types that can have the given entity as an endpoint.

Parameters

string $entity_type: The entity type of the endpoint.

string $bundle: The bundle of the endpoint.

string $endpoint: (optional) the type of endpoint. This is only used for directional relation types. Possible options are 'source', 'target', or 'both'.

Return value

array An array of relation types

1 method overrides RelationRepositoryInterface::getAvailable()
RelationRepository::getAvailable in src/Entity/RelationRepository.php
Returns the relation types that can have the given entity as an endpoint.

File

src/RelationRepositoryInterface.php, line 24

Class

RelationRepositoryInterface
Relation Repository Interface.

Namespace

Drupal\relation

Code

public function getAvailable($entity_type, $bundle, $endpoint = 'source');