Is it possible to have something like this in C#? I am not very sure:
class Library
{
public string Books[string title]
{
get{return this.GetBookByName(string title);}
}
public DateTime PublishingDates[string title]
{
get{return this.GetBookByName(string title).PublishingDate;}
}
}
So it could be used as such:
myLibrary.Books["V For Vendetta"]
myLibrary.PublishingDates["V For Vendetta"] = ...
So my complete member methods that I need to implement in my framework (by calling them) are:
GetCustomStringValue (key)
GetCustomIntValue (key)
GetCustomBoolValue (key)
GetCustomFloatValue (key)
SetCustomStringValue (key)
SetCustomIntValue (key)
SetCustomBoolValue (key)
SetCustomFloatValue (key)
I want to implement them cleaner in my own type.