Closed mansoor945 closed 6 years ago
Hi @mansoor945 thanks for the feedback! There are currently no plans to add complex objects as keys. That was by design, primarily because distributed caches use strings as keys, obviously. To use complex objects, you can/have to implement the transformation to a string yourself. Either override ToString or serialize your key, whatever. It is not really hard to do, that's why I never saw the point of adding and better keep it simple...
Hi @MichaCo,
I have started using your library and it is working great for me.
Right now for Dictionary, Memory Handle and all other handles, only
string
is supported as keys.If you can support Generic Type Keys, it would be great.
Usage
I have an object which identifies unique request which is made to database server. I want to cache the response of the database query, and for that I want the key to be set as that object.
Sample Code
I am looking for something like the below signature:
void Put<T1>(T1 key, TCacheValue value);