6750cfc9fba0b0fbe48bf58e536a33d75fe98010
[phancap.git] / src / phancap / Image.php
1 <?php
2 namespace phancap;
3
4 class Image
5 {
6     protected $config;
7     public $name;
8
9
10     public function __construct($name)
11     {
12         $this->name = $name;
13     }
14
15     public function getPath()
16     {
17         return $this->config->cacheDir . $this->name;
18     }
19
20     public function getUrl()
21     {
22         return $this->config->cacheDirUrl . $this->name;
23     }
24
25     public function setConfig(Config $config)
26     {
27         $this->config = $config;
28     }
29 }
30 ?>