Piotr Korzybski <[EMAIL PROTECTED]> writes:

> When running servlet with servletparmEnum initialized in init() function,
> (but send to output in doGet()) after reloading the first line of the output
> is
>
> There are no Servlet initialization parameters
>

It would help if you sent the source for the code that is not
working, rather than the code that is working.

Otherwise we can't see what you've done wrong, can we?


> When initializing servletparmEnum in doGet, reloading does not
> change the initial output.  I know, init() is called once for
> servlet instance. So why Strings host and name do not "vanish" as
> well?

Because the servlet is still loaded and working.

The problem is that you do not understand the lifetime of the
servlet. You think the servlet is created once per request, it isn't,
it is created once, init() is called and then it services each
request.

Put a println() in the init method to see this working.


> I apologize for so long (and maybe boring) presentation of my
> inquiry.

You should go read some basic servlet introduction for more details.


Nic Ferrier

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

Reply via email to