init-params from web.xml not come in right order

2005-07-07 Thread Sallo Laszlo
Hi,

 

I am using tomcat 4.1.30.

 

I introduced some init-params and I need them in the same order as in 
web.xml. Right now I am getting in an arbitrary order with  :

 

Enumeration urlPatternEnum =  filterConfig.getInitParameterNames();

 

How can I fix this ? Is a higher version of tomcat where this is works ?

 

Best Regards,

Sallo Laszlo


-- 
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.323 / Virus Database: 267.8.10/43 - Release Date: 7/6/2005
 


Re: init-params from web.xml not come in right order

2005-07-07 Thread Mikolaj Rydzewski

Sallo Laszlo wrote:

I introduced some init-params and I need them in the same order as in web.xml. 

Why do you need them this way? I would use another parameter, let's say 
params-list, with ordered list of other parameters' names, i.e.:


param
   nameparams-list/name
   valueparam1, param_other, param_3, param7/value
/param

--
Mikolaj Rydzewski  [EMAIL PROTECTED]
Becomo S.A.
tel. (12) 2927104




smime.p7s
Description: S/MIME Cryptographic Signature


RE: init-params from web.xml not come in right order

2005-07-07 Thread Sallo Laszlo
Hi,

Unfortunately this is not what I need. My list is like :

init-param
param-name/index.jsp/param-name
param-valuenone/param-value
/init-param
init-param
param-name/img/*/param-name
param-valuenone/param-value
/init-param
init-param
param-name/*/param-name
param-valueadmin/param-value
/init-param  

Is a list with some path-role mapping. And I need in this order. I
looked in Context implementation of tomcat and I saw they are using
HashMap-s and that's why it comes arbitrary.

Laszlo

-Original Message-
From: Mikolaj Rydzewski [mailto:[EMAIL PROTECTED] 
Sent: Thursday, July 07, 2005 4:13 PM
To: Tomcat Users List
Subject: Re: init-params from web.xml not come in right order

Sallo Laszlo wrote:

I introduced some init-params and I need them in the same order as in
web.xml. 

Why do you need them this way? I would use another parameter, let's say 
params-list, with ordered list of other parameters' names, i.e.:

param
nameparams-list/name
valueparam1, param_other, param_3, param7/value
/param

-- 
Mikolaj Rydzewski  [EMAIL PROTECTED]
Becomo S.A.
tel. (12) 2927104



-- 
No virus found in this incoming message.
Checked by AVG Anti-Virus.
Version: 7.0.323 / Virus Database: 267.8.10/43 - Release Date: 7/6/2005
 


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: init-params from web.xml not come in right order

2005-07-07 Thread Mikolaj Rydzewski

Sallo Laszlo wrote:


Unfortunately this is not what I need. My list is like :

init-param
param-name/index.jsp/param-name
param-valuenone/param-value
/init-param
init-param
param-name/img/*/param-name
param-valuenone/param-value
/init-param
init-param
param-name/*/param-name
param-valueadmin/param-value
		/init-param  


Is a list with some path-role mapping. And I need in this order. I
looked in Context implementation of tomcat and I saw they are using
HashMap-s and that's why it comes arbitrary.
 


So add another parameter:

init-param
   param-nameparams-order/param-name
   param-value/index.jsp /img/* /*/param-value
/init-param

Tokenize its value with spaces (or some other char) and you are ready to 
read the rest of parameters in the order you want.


--
Mikolaj Rydzewski  [EMAIL PROTECTED]
Becomo S.A.
tel. (12) 2927104




smime.p7s
Description: S/MIME Cryptographic Signature