@@ -122,6 +122,9 @@ discard block |
||
122 | 122 | return $type2extension[$type]; |
123 | 123 | } |
124 | 124 | |
125 | + /** |
|
126 | + * @param string $extension |
|
127 | + */ |
|
125 | 128 | public function getTypeByExtension($extension) |
126 | 129 | { |
127 | 130 | return static::$_extension2type[$extension]; |
@@ -132,6 +135,9 @@ discard block |
||
132 | 135 | return ($this->goal ? $this->goal->fileType : null) ?: static::getTypeByExtension($this->_extension) ?: 'template'; |
133 | 136 | } |
134 | 137 | |
138 | + /** |
|
139 | + * @param string $path |
|
140 | + */ |
|
135 | 141 | public function setPath($path) |
136 | 142 | { |
137 | 143 | $path = Yii::getAlias($path); |
@@ -218,6 +224,9 @@ discard block |
||
218 | 224 | return $this->data = $this->handler->parsePath($this->path, $this->minimalPath); |
219 | 225 | } |
220 | 226 | |
227 | + /** |
|
228 | + * @return string |
|
229 | + */ |
|
221 | 230 | public function read() |
222 | 231 | { |
223 | 232 | return $this->handler->read($this->path); |