protected function getTemplateExtends($templateSource) { preg_match('/@extends\\(\'(.+)\'\\)/', $templateSource, $matches); return array_pop($matches); }