function TypedDataRelationship::getMainPropertyName

Same name in other branches
  1. 4.0.x src/Plugin/Relationship/TypedDataRelationship.php \Drupal\ctools\Plugin\Relationship\TypedDataRelationship::getMainPropertyName()
2 calls to TypedDataRelationship::getMainPropertyName()
TypedDataRelationship::getRelationship in src/Plugin/Relationship/TypedDataRelationship.php
TypedDataRelationship::getRelationshipValue in src/Plugin/Relationship/TypedDataRelationship.php

File

src/Plugin/Relationship/TypedDataRelationship.php, line 78

Class

TypedDataRelationship
Plugin annotation @Relationship( id = "typed_data_relationship", deriver = "\Drupal\ctools\Plugin\Deriver\TypedDataRelationshipDeriver" )

Namespace

Drupal\ctools\Plugin\Relationship

Code

protected function getMainPropertyName(FieldItemInterface $data) {
    return $data->getFieldDefinition()
        ->getFieldStorageDefinition()
        ->getMainPropertyName();
}