commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stephen Colebourne <scolebou...@btopenworld.com>
Subject Re: [lang] org.apache.commons.lang.Entities
Date Thu, 27 Apr 2006 23:07:25 GMT
Gary Gregory wrote:
> - Let users call StringEscapeUtils once to init the data like David
> discovered.
> - Change the init in Entities to lazy-init methods (which must be
> synchronized)
> - Change the init in Entities to use an on-demand holder class 

Would this work? I suspect not.

static {
         Entities xml = new Entities();
         xml.addEntities(BASIC_ARRAY);
         xml.addEntities(APOS_ARRAY);
         XML = xml;
}

I have to be honest that I did think that static blocks were inherently 
synced in Java.

Stephen

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Mime
View raw message