You are here

public function MappedObjectStorage::loadByDrupal in Salesforce Suite 5.0.x

Same name and namespace in other branches
  1. 8.4 modules/salesforce_mapping/src/MappedObjectStorage.php \Drupal\salesforce_mapping\MappedObjectStorage::loadByDrupal()
  2. 8.3 modules/salesforce_mapping/src/MappedObjectStorage.php \Drupal\salesforce_mapping\MappedObjectStorage::loadByDrupal()

Load MappedObjects by entity type id and entity id.

Parameters

string $entity_type_id: Entity type id.

int|string $entity_id: Entity id.

Return value

\Drupal\salesforce_mapping\Entity\MappedObject[] Mapped objects.

See also

loadByProperties()

File

modules/salesforce_mapping/src/MappedObjectStorage.php, line 32

Class

MappedObjectStorage
Class MappedObjectStorage.

Namespace

Drupal\salesforce_mapping

Code

public function loadByDrupal($entity_type_id, $entity_id) {
  return $this
    ->loadByProperties([
    'drupal_entity__target_type' => $entity_type_id,
    'drupal_entity__target_id' => $entity_id,
  ]);
}