identity:C# Generic Identity Map -- Creating an Object Pool for Multiple Object Types

Let's say we need to keep track of objects that have been instantiated in our application. The "Identity Map" pattern does just this and we can implement it with a simple Dictionary<TKey, TValue>. However, we need a different dictionary for each type of object which can become cumbersome to keep track of. Let's look at a technique by which we can have all of our pools in _disibledevent=MsoBodyText>Until next time,
Happy coding

Tags:  selectidentity sqlidentity wowwddgidentity identity

延伸阅读

最新评论

发表评论