/** * @param string $vendor * @param string $package * @param string $category * @param string $message * @param string $version */ private function __construct($vendor, $package, $category, $message, $version) { $this->vendor = $vendor; $this->package = $package; $this->category = $category ?: null; $this->message = $message; $this->version = SchemaVersion::fromString($version); $this->id = sprintf('pbj:%s:%s:%s:%s:%s', $this->vendor, $this->package, $this->category, $this->message, $this->version->toString()); $this->curie = SchemaCurie::fromId($this); }