class JavaPropertiesHelper {

    public Properties getProperties(String propertiesString)
    {
        Properties properties = new Properties();
        StringReader reader = new StringReader(propertiesString);
        try
        {
            properties.load(reader);
        }
        catch (IOException e)
        {
            // This exception should normally not happen as there are not many cases in which a StringReader would throw an error.
            throw new IllegalArgumentException("Error loading properties from string reader. See cause for details.", e);
        }
        return properties;
    }

}