* @param $template The template we shall load
* @param $extOther An other extension to use
* @return void
- * @throws FileNotFoundException If the template was not found
+ * @throws FileIoException If the template was not found
*/
protected function loadTemplate ($template, $extOther = '') {
// Get extension for the template if empty
try {
// Load the raw template data
$this->loadRawTemplateData($fqfn);
- } catch (FileNotFoundException $e) {
+ } catch (FileIoException $e) {
// If we shall load a code-template we need to switch the file extension
if (($this->getTemplateType() != $this->getConfigInstance()->getConfigEntry('web_template_type')) && (empty($extOther))) {
// Switch over to the code-template extension and try it again
$this->loadTemplate($template, $ext);
} else {
// Throw it again
- throw new FileNotFoundException($fqfn, FrameworkFileInputPointer::EXCEPTION_FILE_NOT_FOUND);
+ throw new FileIoException($fqfn, FrameworkFileInputPointer::EXCEPTION_FILE_NOT_FOUND);
}
}
// Remember this template for recursion detection
// RECURSIVE PROTECTION!
$this->loadedTemplates[] = $template;
- } catch (FileNotFoundException $e) {
- // Even this is not done... :/
- $this->rawTemplates[] = $template;
- } catch (FilePointerNotOpenedException $e) {
+ } catch (FileIoException $e) {
// Even this is not done... :/
$this->rawTemplates[] = $template;
}
// Remember this template for recursion detection
// RECURSIVE PROTECTION!
$this->loadedTemplates[] = $template;
- } catch (FileNotFoundException $e) {
- // This template was never found. We silently ignore it
- unset($this->rawTemplates[$key]);
- } catch (FilePointerNotOpenedException $e) {
+ } catch (FileIoException $e) {
// This template was never found. We silently ignore it
unset($this->rawTemplates[$key]);
}