I'm using Castle DictionaryAdapter in order to get the application settings from the app.config as an interface ( based on Getting rid of strings (3): take your app settings to the next level ):
public interface ISettings {
int MaxUsers { get; }
string FeedbackMail { get; }
DateTime LastUserLogin { get; }
}
app.config
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<appSettings>
<add key="MaxUsers" value="20"/>
<add key="FeedbackMail" value="foo@localhost"/>
<add key="LastUserLogin" value="2009-06-15T13:45:30.0900000"/>
</appSettings>
</configuration>
Is it possible to configure DictionaryAdapter to use a custom string format like "yyyyMMdd-HHmm" for converting the value stored in app.config ?