Ejemplo n.º 1
0
 private Template _getTemplate(AbstractTheme theme, String template)
     throws TemplateDoesNotExistException {
   try {
     return engine.getTemplate(theme.getName() + "/" + template);
   } catch (ResourceNotFoundException e) {
     throw new TemplateDoesNotExistException(
         "The template " + template + " for " + theme.getName() + " does not exist");
   }
 }
Ejemplo n.º 2
0
 public Template getTemplate(AbstractTheme theme, String template)
     throws TemplateDoesNotExistException {
   logger.debug("[Finding] " + template + " for " + theme.getName());
   try {
     return _getTemplate(theme, template);
   } catch (TemplateDoesNotExistException e) {
     /* If it goes wrong, try the default theme */
     return _getTemplate(SeventyEight.getInstance().getDefaultTheme(), template);
   }
 }