Locators would also be very useful for ConfigurationFactory to be used in the definition files. This would imply an extensible means of representing Locators as text, so you could write something like
<!-- classpath locator --> <properties locator="classpath:/myproperties"/> <!-- Custom locator --> <xml locator="my.package.MyLocator" params="..."/>
Just a quick shot, this needs to be further elaborated.
I would not add the locator alias in front of the resource name, that would look like an URL, but I like the idea. We could just add a locator attribute :
<properties locator="classpath" fileName="config.properties"/>
Would it make sense to use Locators also for saving configurations? For this purpose a locate() method would be needed that returns an OutputStream.
I don't think so, the location mechanism is specific to the loading of the file, saving is a different beast, once the file has been loaded it's expected to be saved at the same place. That why I didn't want to remove the internal URL in AbstractFileConfiguration.
Emmanuel Bourg
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
