/**
  * @param string $entityId
  */
 public function __construct($entityId)
 {
     Assert::notEmpty($entityId);
     Assert::string($entityId);
     Assert::notBlank($entityId);
     $this->entityId = $entityId;
 }
 public function findAllFor($userId)
 {
     Assert::string($userId, 'User ID "%s" expected to be string, type %s given.');
     Assert::notEmpty($userId, 'User ID "%s" is empty, but non empty value was expected.');
     $consentListJson = $this->apiClient->read('consent/%s', [$userId]);
     return ConsentListFactory::createListFromMetadata($consentListJson);
 }
示例#3
0
 /**
  * @param string $locale
  */
 public function __construct($locale)
 {
     Assert::string($locale);
     Assert::notEmpty($locale);
     $this->locale = $locale;
 }