From: Marc P. <ma...@an...> - 2003-03-26 21:49:20
|
On Wed, 26 Mar 2003 13:38:28 -0800, Brian Goetz <br...@qu...> wrote: > Here's the problem with Properties -- we want to have this > one-size-fits-all, lazy initialization idiom. Its easy to tell when > two servlets refer to the same servlet context. Its easy to tell when > two file names are the same. It wasn't at the time easy to tell that > two Properties are actually the same set (now that Hashtable and > HashMap have been merged, Hashtable follows the equals/hashCode > requirements of Map.) (And its still not all that lightweight.) > > But given that Properties now is Map-compliant, adding WM(Properties) > and WM(Servlet, Properties) isn't that hard. I'll do this. That would be great if you could... but in terms of getting a unique broker instance per Servlet + Properties combination, that's going to be a bit more tricky isn't it? You'll have to wrap the ServletContext + Properties in a new object to use as a key for findBroker, and implement hashcode and equals, right? -- Marc Palmer |