Velocity Reviews

Velocity Reviews (
-   Java (
-   -   Re: servlets - application level object (

Phil Hanna 07-02-2003 02:37 AM

Re: servlets - application level object
On Tue, 01 Jul 2003 00:06:35 GMT, "Miguel De Anda"
<> wrote:

>Is there some application level object that I can use to store settings such
>as database connection info and directory settings? I need something that is
>at least readable throughout my servlets (writing settings after initialized
>is not important).

A simple way is to put a file in the /WEB-INF directory, and read it
with ServletContext.getResourceAsStream("/WEB-INF/myfile");
Phil Hanna
Author of JSP 2.0: The Complete Reference

All times are GMT. The time now is 08:53 PM.

Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.