
6 Sep
2010
6 Sep
'10
8:28 p.m.
On Sat, Sep 4, 2010 at 4:44 AM, Yakov Galka <ybungalobill@gmail.com> wrote:
Can you give an example for when you need these events? Why can't you do initialization where you create the context and destruction where you destroy it? Probably 'resources' will be stored in some object that will be responsible for the context so binding their lifetimes sounds logical. I don't want double construction/destruction as in MFC/WTL.
A creation event may not be useful, but an event for destruction could be used to tell whatever is managing the resources (if any) to release them. In the end the usefulness of these events comes down to how the library is designed.