This content has been marked as final. Show 3 replies
I need to parse a properties file which has entries which have space in the key.
First\ Name = xxx
loadUserProperties.getProperty("First Name") is throwing null pointer exception.It does not throw NPE for me...
... this file is provided by some third party and I have no control on the keys in the file.Unless the spaces in the keys are escaped
the supplier of the file has a problem.
I need to get the values from that properties file for further processing.java.util.Properties gives you propertyNames() and it extends Hashtable so you get elements(), entrySet(), keys(), keySet()
so that should not be a problem.
Edited by: tschodt on Dec 13, 2010 5:28 PM