package org.seasar.jsf.runtime;

import java.io.File;

import org.seasar.jsf.TagProcessor;
import org.seasar.jsf.ViewTemplate;

/**
 * @author higa
 *  
 */
public class ViewTemplateImpl implements ViewTemplate {

	private TagProcessor rootTagProcessor;

	private File file;

	private long lastModified;

	public ViewTemplateImpl(TagProcessor rootTagProcessor, File file) {
		this.rootTagProcessor = rootTagProcessor;
		this.file = file;
		this.lastModified = file.lastModified();
	}

	public TagProcessor getRootTagProcessor() {
		return rootTagProcessor;
	}

	public boolean isModified() {
		return file.lastModified() > lastModified;
	}
}