private function __construct($aggregateType) { if (!is_string($aggregateType) || empty($aggregateType)) { throw new Exception\InvalidArgumentException('AggregateType must be a non empty string'); } $this->aggregateType = $aggregateType; }