header = $header; $this->body = $body; $this->signature = $signature; $this->origin = $origin; } public function getHeader() { return $this->header; } public function getHash() { return sha1($this->body); } public function getSignature() { return $this->signature; } public function getBody() { return $this->body; } protected function load($hotfix) { if (strpos($hotfix, "\n---\n")===false) { throw new \Exception("Hotfix is missing a proper header, is line endings wrong?"); } list ($header, $body) = explode("\n---\n", $hotfix, 2); $header = Yaml::parse($header); $this->header = $header; $this->body = $body; } public function apply() { $runner = RunnerFactory::createRunner($this); $runner->apply(); } }