Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
  * Copyright 2014 Attila Szegedi, Daniel Dekany, Jonathan Revusky
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
  * You may obtain a copy of the License at
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * See the License for the specific language governing permissions and
 * limitations under the License.
package freemarker.template;
Thrown when Configuration.getTemplate(java.lang.String) (or similar) doesn't find a template. This extends for backward compatibility, but in fact has nothing to do with files, as FreeMarker can load templates from many other sources.

public final class TemplateNotFoundException extends FileNotFoundException {
    private final String templateName;
    private final Object customLookupCondition;
    public TemplateNotFoundException(String templateNameObject customLookupConditionString message) {
        this. = templateName;
        this. = customLookupCondition;

The name (path) of the template that wasn't found.
    public String getTemplateName() {
        return ;

The custom lookup condition with which the template was requested, or null if there's no such condition. See the customLookupCondition parameter of Configuration.getTemplate(java.lang.String,java.util.Locale,java.lang.Object,java.lang.String,boolean,boolean).
    public Object getCustomLookupCondition() {
        return ;
New to GrepCode? Check out our FAQ X