blob: 1de398ad9c7c374f3b86667599bfab96729ecc76 [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!--NewPage-->
<HTML>
<HEAD>
<!-- Generated by javadoc (build 1.6.0_22) on Mon Nov 29 23:49:20 PST 2010 -->
<META http-equiv="Content-Type" content="text/html; charset=UTF-8">
<TITLE>
ResourceManagerImpl (Apache Velocity 1.7 API)
</TITLE>
<META NAME="date" CONTENT="2010-11-29">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
<SCRIPT type="text/javascript">
function windowTitle()
{
if (location.href.indexOf('is-external=true') == -1) {
parent.document.title="ResourceManagerImpl (Apache Velocity 1.7 API)";
}
}
</SCRIPT>
<NOSCRIPT>
</NOSCRIPT>
</HEAD>
<BODY BGCOLOR="white" onload="windowTitle();">
<HR>
<!-- ========= START OF TOP NAVBAR ======= -->
<A NAME="navbar_top"><!-- --></A>
<A HREF="#skip-navbar_top" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_top_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
<TR ALIGN="center" VALIGN="top">
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/ResourceManagerImpl.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
</TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;<A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManager.html" title="interface in org.apache.velocity.runtime.resource"><B>PREV CLASS</B></A>&nbsp;
&nbsp;NEXT CLASS</FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../../../index.html?org/apache/velocity/runtime/resource/ResourceManagerImpl.html" target="_top"><B>FRAMES</B></A> &nbsp;
&nbsp;<A HREF="ResourceManagerImpl.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
&nbsp;<SCRIPT type="text/javascript">
<!--
if(window==top) {
document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
}
//-->
</SCRIPT>
<NOSCRIPT>
<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
</NOSCRIPT>
</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;<A HREF="#field_summary">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL:&nbsp;<A HREF="#field_detail">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_top"></A>
<!-- ========= END OF TOP NAVBAR ========= -->
<HR>
<!-- ======== START OF CLASS DATA ======== -->
<H2>
<FONT SIZE="-1">
org.apache.velocity.runtime.resource</FONT>
<BR>
Class ResourceManagerImpl</H2>
<PRE>
<A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
<IMG SRC="../../../../../resources/inherit.gif" ALT="extended by "><B>org.apache.velocity.runtime.resource.ResourceManagerImpl</B>
</PRE>
<DL>
<DT><B>All Implemented Interfaces:</B> <DD><A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManager.html" title="interface in org.apache.velocity.runtime.resource">ResourceManager</A></DD>
</DL>
<HR>
<DL>
<DT><PRE>public class <B>ResourceManagerImpl</B><DT>extends <A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A><DT>implements <A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManager.html" title="interface in org.apache.velocity.runtime.resource">ResourceManager</A></DL>
</PRE>
<P>
Class to manage the text resource for the Velocity Runtime.
<P>
<P>
<DL>
<DT><B>Version:</B></DT>
<DD>$Id: ResourceManagerImpl.java 745757 2009-02-19 06:48:10Z nbubna $</DD>
<DT><B>Author:</B></DT>
<DD><a href="mailto:wglass@forio.com">Will Glass-Husain</a>, <a href="mailto:jvanzyl@apache.org">Jason van Zyl</a>, <a href="mailto:paulo.gaspar@krankikom.de">Paulo Gaspar</a>, <a href="mailto:geirm@optonline.net">Geir Magnusson Jr.</a>, <a href="mailto:henning@apache.org">Henning P. Schmiedehausen</a></DD>
</DL>
<HR>
<P>
<!-- =========== FIELD SUMMARY =========== -->
<A NAME="field_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Field Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected &nbsp;<A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceCache.html" title="interface in org.apache.velocity.runtime.resource">ResourceCache</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManagerImpl.html#globalCache">globalCache</A></B></CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Object implementing ResourceCache to be our resource manager's Resource cache.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected &nbsp;<A HREF="../../../../../org/apache/velocity/runtime/log/Log.html" title="class in org.apache.velocity.runtime.log">Log</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManagerImpl.html#log">log</A></B></CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Logging.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManagerImpl.html#RESOURCE_CONTENT">RESOURCE_CONTENT</A></B></CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;A static content resource.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManagerImpl.html#RESOURCE_TEMPLATE">RESOURCE_TEMPLATE</A></B></CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;A template resources.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected &nbsp;<A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/util/List.html?is-external=true" title="class or interface in java.util">List</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManagerImpl.html#resourceLoaders">resourceLoaders</A></B></CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The List of templateLoaders that the Runtime will use to locate the InputStream source of a template.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected &nbsp;<A HREF="../../../../../org/apache/velocity/runtime/RuntimeServices.html" title="interface in org.apache.velocity.runtime">RuntimeServices</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManagerImpl.html#rsvc">rsvc</A></B></CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The internal RuntimeServices object.</TD>
</TR>
</TABLE>
&nbsp;
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<A NAME="constructor_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Constructor Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManagerImpl.html#ResourceManagerImpl()">ResourceManagerImpl</A></B>()</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
</TR>
</TABLE>
&nbsp;
<!-- ========== METHOD SUMMARY =========== -->
<A NAME="method_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Method Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected &nbsp;<A HREF="../../../../../org/apache/velocity/runtime/resource/Resource.html" title="class in org.apache.velocity.runtime.resource">Resource</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManagerImpl.html#createResource(java.lang.String, int)">createResource</A></B>(<A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;resourceName,
int&nbsp;resourceType)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Create a new Resource of the specified type.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;<A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManagerImpl.html#getLoaderNameForResource(java.lang.String)">getLoaderNameForResource</A></B>(<A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;resourceName)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Determines if a template exists, and returns name of the loader that provides it.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;<A HREF="../../../../../org/apache/velocity/runtime/resource/Resource.html" title="class in org.apache.velocity.runtime.resource">Resource</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManagerImpl.html#getResource(java.lang.String, int)">getResource</A></B>(<A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;resourceName,
int&nbsp;resourceType)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>Deprecated.</B>&nbsp;<I>Use <A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManagerImpl.html#getResource(java.lang.String, int, java.lang.String)"><CODE>getResource(String resourceName, int resourceType, String encoding )</CODE></A></I></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;<A HREF="../../../../../org/apache/velocity/runtime/resource/Resource.html" title="class in org.apache.velocity.runtime.resource">Resource</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManagerImpl.html#getResource(java.lang.String, int, java.lang.String)">getResource</A></B>(<A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;resourceName,
int&nbsp;resourceType,
<A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;encoding)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Gets the named resource.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManagerImpl.html#initialize(org.apache.velocity.runtime.RuntimeServices)">initialize</A></B>(<A HREF="../../../../../org/apache/velocity/runtime/RuntimeServices.html" title="interface in org.apache.velocity.runtime">RuntimeServices</A>&nbsp;rsvc)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Initialize the ResourceManager.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected &nbsp;<A HREF="../../../../../org/apache/velocity/runtime/resource/Resource.html" title="class in org.apache.velocity.runtime.resource">Resource</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManagerImpl.html#loadResource(java.lang.String, int, java.lang.String)">loadResource</A></B>(<A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;resourceName,
int&nbsp;resourceType,
<A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;encoding)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Loads a resource from the current set of resource loaders.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected &nbsp;<A HREF="../../../../../org/apache/velocity/runtime/resource/Resource.html" title="class in org.apache.velocity.runtime.resource">Resource</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManagerImpl.html#refreshResource(org.apache.velocity.runtime.resource.Resource, java.lang.String)">refreshResource</A></B>(<A HREF="../../../../../org/apache/velocity/runtime/resource/Resource.html" title="class in org.apache.velocity.runtime.resource">Resource</A>&nbsp;resource,
<A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;encoding)</CODE>
<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Takes an existing resource, and 'refreshes' it.</TD>
</TR>
</TABLE>
&nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Object.html?is-external=true#clone()" title="class or interface in java.lang">clone</A>, <A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang">equals</A>, <A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Object.html?is-external=true#finalize()" title="class or interface in java.lang">finalize</A>, <A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Object.html?is-external=true#getClass()" title="class or interface in java.lang">getClass</A>, <A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Object.html?is-external=true#hashCode()" title="class or interface in java.lang">hashCode</A>, <A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Object.html?is-external=true#notify()" title="class or interface in java.lang">notify</A>, <A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Object.html?is-external=true#notifyAll()" title="class or interface in java.lang">notifyAll</A>, <A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Object.html?is-external=true#toString()" title="class or interface in java.lang">toString</A>, <A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Object.html?is-external=true#wait()" title="class or interface in java.lang">wait</A>, <A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Object.html?is-external=true#wait(long)" title="class or interface in java.lang">wait</A>, <A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
</TR>
</TABLE>
&nbsp;
<P>
<!-- ============ FIELD DETAIL =========== -->
<A NAME="field_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
<B>Field Detail</B></FONT></TH>
</TR>
</TABLE>
<A NAME="RESOURCE_TEMPLATE"><!-- --></A><H3>
RESOURCE_TEMPLATE</H3>
<PRE>
public static final int <B>RESOURCE_TEMPLATE</B></PRE>
<DL>
<DD>A template resources.
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../../../../constant-values.html#org.apache.velocity.runtime.resource.ResourceManagerImpl.RESOURCE_TEMPLATE">Constant Field Values</A></DL>
</DL>
<HR>
<A NAME="RESOURCE_CONTENT"><!-- --></A><H3>
RESOURCE_CONTENT</H3>
<PRE>
public static final int <B>RESOURCE_CONTENT</B></PRE>
<DL>
<DD>A static content resource.
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../../../../constant-values.html#org.apache.velocity.runtime.resource.ResourceManagerImpl.RESOURCE_CONTENT">Constant Field Values</A></DL>
</DL>
<HR>
<A NAME="globalCache"><!-- --></A><H3>
globalCache</H3>
<PRE>
protected <A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceCache.html" title="interface in org.apache.velocity.runtime.resource">ResourceCache</A> <B>globalCache</B></PRE>
<DL>
<DD>Object implementing ResourceCache to be our resource manager's Resource cache.
<P>
<DL>
</DL>
</DL>
<HR>
<A NAME="resourceLoaders"><!-- --></A><H3>
resourceLoaders</H3>
<PRE>
protected final <A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/util/List.html?is-external=true" title="class or interface in java.util">List</A> <B>resourceLoaders</B></PRE>
<DL>
<DD>The List of templateLoaders that the Runtime will use to locate the InputStream source of a template.
<P>
<DL>
</DL>
</DL>
<HR>
<A NAME="rsvc"><!-- --></A><H3>
rsvc</H3>
<PRE>
protected <A HREF="../../../../../org/apache/velocity/runtime/RuntimeServices.html" title="interface in org.apache.velocity.runtime">RuntimeServices</A> <B>rsvc</B></PRE>
<DL>
<DD>The internal RuntimeServices object.
<P>
<DL>
</DL>
</DL>
<HR>
<A NAME="log"><!-- --></A><H3>
log</H3>
<PRE>
protected <A HREF="../../../../../org/apache/velocity/runtime/log/Log.html" title="class in org.apache.velocity.runtime.log">Log</A> <B>log</B></PRE>
<DL>
<DD>Logging.
<P>
<DL>
</DL>
</DL>
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<A NAME="constructor_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
<B>Constructor Detail</B></FONT></TH>
</TR>
</TABLE>
<A NAME="ResourceManagerImpl()"><!-- --></A><H3>
ResourceManagerImpl</H3>
<PRE>
public <B>ResourceManagerImpl</B>()</PRE>
<DL>
</DL>
<!-- ============ METHOD DETAIL ========== -->
<A NAME="method_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
<B>Method Detail</B></FONT></TH>
</TR>
</TABLE>
<A NAME="initialize(org.apache.velocity.runtime.RuntimeServices)"><!-- --></A><H3>
initialize</H3>
<PRE>
public void <B>initialize</B>(<A HREF="../../../../../org/apache/velocity/runtime/RuntimeServices.html" title="interface in org.apache.velocity.runtime">RuntimeServices</A>&nbsp;rsvc)</PRE>
<DL>
<DD>Initialize the ResourceManager.
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManager.html#initialize(org.apache.velocity.runtime.RuntimeServices)">initialize</A></CODE> in interface <CODE><A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManager.html" title="interface in org.apache.velocity.runtime.resource">ResourceManager</A></CODE></DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>rsvc</CODE> - The Runtime Services object which is associated with this Resource Manager.</DL>
</DD>
</DL>
<HR>
<A NAME="getResource(java.lang.String, int, java.lang.String)"><!-- --></A><H3>
getResource</H3>
<PRE>
public <A HREF="../../../../../org/apache/velocity/runtime/resource/Resource.html" title="class in org.apache.velocity.runtime.resource">Resource</A> <B>getResource</B>(<A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;resourceName,
int&nbsp;resourceType,
<A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;encoding)
throws <A HREF="../../../../../org/apache/velocity/exception/ResourceNotFoundException.html" title="class in org.apache.velocity.exception">ResourceNotFoundException</A>,
<A HREF="../../../../../org/apache/velocity/exception/ParseErrorException.html" title="class in org.apache.velocity.exception">ParseErrorException</A></PRE>
<DL>
<DD>Gets the named resource. Returned class type corresponds to specified type (i.e. <code>Template</code> to <code>
RESOURCE_TEMPLATE</code>).
This method is now unsynchronized which requires that ResourceCache
implementations be thread safe (as the default is).
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManager.html#getResource(java.lang.String, int, java.lang.String)">getResource</A></CODE> in interface <CODE><A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManager.html" title="interface in org.apache.velocity.runtime.resource">ResourceManager</A></CODE></DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>resourceName</CODE> - The name of the resource to retrieve.<DD><CODE>resourceType</CODE> - The type of resource (<code>RESOURCE_TEMPLATE</code>, <code>RESOURCE_CONTENT</code>, etc.).<DD><CODE>encoding</CODE> - The character encoding to use.
<DT><B>Returns:</B><DD>Resource with the template parsed and ready.
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../../../org/apache/velocity/exception/ResourceNotFoundException.html" title="class in org.apache.velocity.exception">ResourceNotFoundException</A></CODE> - if template not found from any available source.
<DD><CODE><A HREF="../../../../../org/apache/velocity/exception/ParseErrorException.html" title="class in org.apache.velocity.exception">ParseErrorException</A></CODE> - if template cannot be parsed due to syntax (or other) error.</DL>
</DD>
</DL>
<HR>
<A NAME="createResource(java.lang.String, int)"><!-- --></A><H3>
createResource</H3>
<PRE>
protected <A HREF="../../../../../org/apache/velocity/runtime/resource/Resource.html" title="class in org.apache.velocity.runtime.resource">Resource</A> <B>createResource</B>(<A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;resourceName,
int&nbsp;resourceType)</PRE>
<DL>
<DD>Create a new Resource of the specified type.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>resourceName</CODE> - The name of the resource to retrieve.<DD><CODE>resourceType</CODE> - The type of resource (<code>RESOURCE_TEMPLATE</code>, <code>RESOURCE_CONTENT</code>, etc.).
<DT><B>Returns:</B><DD>new instance of appropriate resource type<DT><B>Since:</B></DT>
<DD>1.6</DD>
</DL>
</DD>
</DL>
<HR>
<A NAME="loadResource(java.lang.String, int, java.lang.String)"><!-- --></A><H3>
loadResource</H3>
<PRE>
protected <A HREF="../../../../../org/apache/velocity/runtime/resource/Resource.html" title="class in org.apache.velocity.runtime.resource">Resource</A> <B>loadResource</B>(<A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;resourceName,
int&nbsp;resourceType,
<A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;encoding)
throws <A HREF="../../../../../org/apache/velocity/exception/ResourceNotFoundException.html" title="class in org.apache.velocity.exception">ResourceNotFoundException</A>,
<A HREF="../../../../../org/apache/velocity/exception/ParseErrorException.html" title="class in org.apache.velocity.exception">ParseErrorException</A></PRE>
<DL>
<DD>Loads a resource from the current set of resource loaders.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>resourceName</CODE> - The name of the resource to retrieve.<DD><CODE>resourceType</CODE> - The type of resource (<code>RESOURCE_TEMPLATE</code>, <code>RESOURCE_CONTENT</code>, etc.).<DD><CODE>encoding</CODE> - The character encoding to use.
<DT><B>Returns:</B><DD>Resource with the template parsed and ready.
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../../../org/apache/velocity/exception/ResourceNotFoundException.html" title="class in org.apache.velocity.exception">ResourceNotFoundException</A></CODE> - if template not found from any available source.
<DD><CODE><A HREF="../../../../../org/apache/velocity/exception/ParseErrorException.html" title="class in org.apache.velocity.exception">ParseErrorException</A></CODE> - if template cannot be parsed due to syntax (or other) error.</DL>
</DD>
</DL>
<HR>
<A NAME="refreshResource(org.apache.velocity.runtime.resource.Resource, java.lang.String)"><!-- --></A><H3>
refreshResource</H3>
<PRE>
protected <A HREF="../../../../../org/apache/velocity/runtime/resource/Resource.html" title="class in org.apache.velocity.runtime.resource">Resource</A> <B>refreshResource</B>(<A HREF="../../../../../org/apache/velocity/runtime/resource/Resource.html" title="class in org.apache.velocity.runtime.resource">Resource</A>&nbsp;resource,
<A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;encoding)
throws <A HREF="../../../../../org/apache/velocity/exception/ResourceNotFoundException.html" title="class in org.apache.velocity.exception">ResourceNotFoundException</A>,
<A HREF="../../../../../org/apache/velocity/exception/ParseErrorException.html" title="class in org.apache.velocity.exception">ParseErrorException</A></PRE>
<DL>
<DD>Takes an existing resource, and 'refreshes' it. This generally means that the source of the resource is checked for changes
according to some cache/check algorithm and if the resource changed, then the resource data is reloaded and re-parsed.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>resource</CODE> - resource to refresh<DD><CODE>encoding</CODE> - character encoding of the resource to refresh.
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../../../org/apache/velocity/exception/ResourceNotFoundException.html" title="class in org.apache.velocity.exception">ResourceNotFoundException</A></CODE> - if template not found from current source for this Resource
<DD><CODE><A HREF="../../../../../org/apache/velocity/exception/ParseErrorException.html" title="class in org.apache.velocity.exception">ParseErrorException</A></CODE> - if template cannot be parsed due to syntax (or other) error.</DL>
</DD>
</DL>
<HR>
<A NAME="getResource(java.lang.String, int)"><!-- --></A><H3>
getResource</H3>
<PRE>
public <A HREF="../../../../../org/apache/velocity/runtime/resource/Resource.html" title="class in org.apache.velocity.runtime.resource">Resource</A> <B>getResource</B>(<A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;resourceName,
int&nbsp;resourceType)
throws <A HREF="../../../../../org/apache/velocity/exception/ResourceNotFoundException.html" title="class in org.apache.velocity.exception">ResourceNotFoundException</A>,
<A HREF="../../../../../org/apache/velocity/exception/ParseErrorException.html" title="class in org.apache.velocity.exception">ParseErrorException</A>,
<A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Exception.html?is-external=true" title="class or interface in java.lang">Exception</A></PRE>
<DL>
<DD><B>Deprecated.</B>&nbsp;<I>Use <A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManagerImpl.html#getResource(java.lang.String, int, java.lang.String)"><CODE>getResource(String resourceName, int resourceType, String encoding )</CODE></A></I>
<P>
<DD>Gets the named resource. Returned class type corresponds to specified type (i.e. <code>Template</code> to <code>
RESOURCE_TEMPLATE</code>).
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>resourceName</CODE> - The name of the resource to retrieve.<DD><CODE>resourceType</CODE> - The type of resource (<code>RESOURCE_TEMPLATE</code>, <code>RESOURCE_CONTENT</code>, etc.).
<DT><B>Returns:</B><DD>Resource with the template parsed and ready.
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../../../org/apache/velocity/exception/ResourceNotFoundException.html" title="class in org.apache.velocity.exception">ResourceNotFoundException</A></CODE> - if template not found from any available source.
<DD><CODE><A HREF="../../../../../org/apache/velocity/exception/ParseErrorException.html" title="class in org.apache.velocity.exception">ParseErrorException</A></CODE> - if template cannot be parsed due to syntax (or other) error.
<DD><CODE><A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Exception.html?is-external=true" title="class or interface in java.lang">Exception</A></CODE> - if a problem in parse</DL>
</DD>
</DL>
<HR>
<A NAME="getLoaderNameForResource(java.lang.String)"><!-- --></A><H3>
getLoaderNameForResource</H3>
<PRE>
public <A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>getLoaderNameForResource</B>(<A HREF="http://java.sun.com/j2se/1.4.2/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;resourceName)</PRE>
<DL>
<DD>Determines if a template exists, and returns name of the loader that provides it. This is a slightly less hokey way to
support the Velocity.templateExists() utility method, which was broken when per-template encoding was introduced. We can
revisit this.
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManager.html#getLoaderNameForResource(java.lang.String)">getLoaderNameForResource</A></CODE> in interface <CODE><A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManager.html" title="interface in org.apache.velocity.runtime.resource">ResourceManager</A></CODE></DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>resourceName</CODE> - Name of template or content resource
<DT><B>Returns:</B><DD>class name of loader than can provide it</DL>
</DD>
</DL>
<!-- ========= END OF CLASS DATA ========= -->
<HR>
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<A NAME="navbar_bottom"><!-- --></A>
<A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_bottom_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
<TR ALIGN="center" VALIGN="top">
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/ResourceManagerImpl.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
</TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;<A HREF="../../../../../org/apache/velocity/runtime/resource/ResourceManager.html" title="interface in org.apache.velocity.runtime.resource"><B>PREV CLASS</B></A>&nbsp;
&nbsp;NEXT CLASS</FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../../../index.html?org/apache/velocity/runtime/resource/ResourceManagerImpl.html" target="_top"><B>FRAMES</B></A> &nbsp;
&nbsp;<A HREF="ResourceManagerImpl.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
&nbsp;<SCRIPT type="text/javascript">
<!--
if(window==top) {
document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
}
//-->
</SCRIPT>
<NOSCRIPT>
<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
</NOSCRIPT>
</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;<A HREF="#field_summary">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL:&nbsp;<A HREF="#field_detail">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_bottom"></A>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
<HR>
Copyright &#169; 2000-2010 <a href="http://www.apache.org/">The Apache Software Foundation</a>. All Rights Reserved.
</BODY>
</HTML>