Hi. Andrew Haley schrieb: >> What is the public equivalent for GetPropertyAction? > > There isn't any need, is there? That depends. :)
> It's just a wrapper for
> (String) AccessController.doPrivileged(new PrivilegedAction() {
> public java.lang.Object run() {
> return System.getProperty(prop); }
> });
That is certainly true but has the nasty side effect of creating an
anonymous class per code location. In the PhoneME code I found ~20
occurrences of GetPropertyAction. Even in Classpath we avoided that by
introducing our own wrapper class.
Regards
Robert
signature.asc
Description: OpenPGP digital signature
