You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by "Oliver Heger (JIRA)" <ji...@apache.org> on 2007/01/27 19:38:49 UTC
[jira] Updated: (CONFIGURATION-222) Saving PropertiesConfiguration
created with PropertiesConfiguration() constructor creates empty files
[ https://issues.apache.org/jira/browse/CONFIGURATION-222?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Oliver Heger updated CONFIGURATION-222:
---------------------------------------
Fix Version/s: (was: Nightly Builds)
1.3
> Saving PropertiesConfiguration created with PropertiesConfiguration() constructor creates empty files
> -----------------------------------------------------------------------------------------------------
>
> Key: CONFIGURATION-222
> URL: https://issues.apache.org/jira/browse/CONFIGURATION-222
> Project: Commons Configuration
> Issue Type: Bug
> Environment: 1.3RC1
> Reporter: Gabriele Garuglieri
> Fix For: 1.3
>
> Attachments: layout.patch
>
>
> The introduction of PropertiesConfigurationLayout broke the saving of in memory created PropertesConfiguration.
> This piece of code will yield empt saved file:
> PropertiesConfiguration pc = new PropertiesConfiguration();
> pc.addProperty("string", "value1");
> pc.save("testsave.properties");
> The problem is that no PropertiesConfigurationLayout is created and EVENT_ADD_PROPERTY is lost.
> Then when saving, an empty PropertiesConfigurationLayout is created and nothing is saved in output file.
> Added creation of PropertiesConfigurationLayout to PropertiesConfiguration() contructor, changed setLayout() to enforce that only one layout per PropertiesConfiguration must exist and added a testcase for this condition.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org