You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@velocity.apache.org by ge...@apache.org on 2001/11/02 04:28:50 UTC
cvs commit: jakarta-velocity/src/java/org/apache/velocity/app Velocity.java VelocityEngine.java
geirm 01/11/01 19:28:50
Modified: src/java/org/apache/velocity/app Velocity.java
VelocityEngine.java
Log:
Forgot to commit these - needed to actually set the app context.
Revision Changes Path
1.24 +15 -1 jakarta-velocity/src/java/org/apache/velocity/app/Velocity.java
Index: Velocity.java
===================================================================
RCS file: /home/cvs/jakarta-velocity/src/java/org/apache/velocity/app/Velocity.java,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -r1.23 -r1.24
--- Velocity.java 2001/09/07 05:05:14 1.23
+++ Velocity.java 2001/11/02 03:28:49 1.24
@@ -108,7 +108,7 @@
* @author <a href="mailto:geirm@optonline.net">Geir Magnusson Jr.</a>
* @author <a href="Christoph.Reck@dlr.de">Christoph Reck</a>
* @author <a href="jvanzyl@apache.org">Jason van Zyl</a>
- * @version $Id: Velocity.java,v 1.23 2001/09/07 05:05:14 geirm Exp $
+ * @version $Id: Velocity.java,v 1.24 2001/11/02 03:28:49 geirm Exp $
*/
public class Velocity implements RuntimeConstants
@@ -632,6 +632,20 @@
RuntimeSingleton.debug( message );
}
+ /**
+ * Set the ApplicationContext, which is an Object
+ * of the applications choice which is accessable from
+ * any component of the system that gets a RuntimeServices.
+ * This allows communication between the application
+ * environment and custom pluggable components of the
+ * Velocity engine, such as loaders and loggers.
+ *
+ * @param Object object to store as ApplicationContext
+ */
+ public static void setApplicationContext( Object o )
+ {
+ RuntimeSingleton.getRuntimeInstance().setApplicationContext( o );
+ }
}
1.3 +15 -1 jakarta-velocity/src/java/org/apache/velocity/app/VelocityEngine.java
Index: VelocityEngine.java
===================================================================
RCS file: /home/cvs/jakarta-velocity/src/java/org/apache/velocity/app/VelocityEngine.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- VelocityEngine.java 2001/09/07 05:05:14 1.2
+++ VelocityEngine.java 2001/11/02 03:28:49 1.3
@@ -106,7 +106,7 @@
* </p>
*
* @author <a href="mailto:geirm@optonline.net">Geir Magnusson Jr.</a>
- * @version $Id: VelocityEngine.java,v 1.2 2001/09/07 05:05:14 geirm Exp $
+ * @version $Id: VelocityEngine.java,v 1.3 2001/11/02 03:28:49 geirm Exp $
*/
public class VelocityEngine implements RuntimeConstants
{
@@ -631,6 +631,20 @@
ri.debug( message );
}
+ /**
+ * Set the ApplicationContext, which is an Object
+ * of the applications choice which is accessable from
+ * any component of the system that gets a RuntimeServices.
+ * This allows communication between the application
+ * environment and custom pluggable components of the
+ * Velocity engine, such as loaders and loggers.
+ *
+ * @param Object object to store as ApplicationContext
+ */
+ public void setApplicationContext( Object o )
+ {
+ ri.setApplicationContext( o );
+ }
}
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>