public function __toString() { $url = "https://gist.githubusercontent.com/{$this->userId}/{$this->gistId}/raw"; if ($this->revision) { $url .= "/{$this->revision}"; } if ($this->filename) { $url .= "/{$this->filename}"; } return $url; }