On 14/11/2011 13:19, Neil Richards wrote:
:
Of course, there are certain situations where the Java documentation
guides you to specify property values which are not String objects.
One that springs to my mind is the setting of "java.naming.corba.orb" to
point to the ORB instance to be used by the JNDI/COS Naming Service
Provider [1].
(For those using this provider, this setting tends to be important in
limiting the resources it consumes).
So I'm not sure it's correct to assume that it is an error for Property
settings to have non-String values.
Neil - I think this is a property that is specified in the JNDI
environment (so Hashtable<?,?> rather than Properties). The only method
that is impacted by the discussion here is System.clearProperty which
has always thrown CastClassException if invoked to remove a property
that doesn't have a String value. I think we're concluding that the only
thing we do can is fix it so that it doesn't remove the property when it
fails (and clarify the javadoc accordingly).
-Alan.