[xwiki-dev] [patch proposal] regex handling in XWiki core

Vincent Massol vincent at massol.net
Tue Feb 13 15:02:00 CET 2007


Hi Pablo,

On Feb 13, 2007, at 9:54 AM, Pablo Oliveira wrote:

> Hi,
>
> As some of you may know, I am currently working on a version of  
> XWiki for
> mobile devices.
> I have been investigating the possibility of running some parts of  
> XWiki
> on a J2ME - CDC PP configuration.
>
> During this process I have noticed that XWiki uses two different  
> api for
> matching regular expressions:
>    * Jakarta ORO
>    * java.util.regex ( JDK > 1.4 )
>
> Because j2me does not have the java.util.regex classes, I have made
> some small changes so that the core of XWiki only uses Jakarta ORO,
> so I can continue my tests.
>
> Yet, I think these changes (see attached patch) may be of a more  
> general
> interest because:
>    * it might be cleaner to stick to a single regex lib
>    * this patch factors some of the regex handling on an
>      encapsulating class that would allow us to change the regex
>      underlying implementation more easily.
>
> What do you think?

I really don't think we should use ORO at all, now that Regexp is  
included in the JDK (since 1.4). We should really get rid of ORO.

I think it's going to be hard not to use any 1.4 features, especially  
as XWiki is based on 1.4 right now. We've already decided to stay 1.4  
compatible. I don't think we can decide to stay 1.3 compatible...

As Ludovic was saying, if we plan ahead, all mobiles devices will  
have a JDK 1.4 compliance level in not too long...

Note sure how this will help you though Pablo. We need to find a  
solution. Has anyone researched if there's a java.util.regexp  
implementation for 1.3?

Thanks
-Vincent

	

	
		
___________________________________________________________________________ 
Yahoo! Mail réinvente le mail ! Découvrez le nouveau Yahoo! Mail et son interface révolutionnaire.
http://fr.mail.yahoo.com




More information about the devs mailing list