01-03-2007, 08:36 PM
OK. Well, that's a bummer, because that's going to require a good bit of magic behind the scenes to make that work. You can't destroy a connection object until you've cleaned up all of the statements that are open against it. Which, if you are just stopping the IDE and it has to clean up, it can't know these things.
So I guess I'm going to have to have the statement objects internally reference count their associated connection handles, so that it doesn't actually get destroyed until all the statements are destroyed that reference it, even if you destroy the connection object.
If I'd realized this, I probably wouldn't have even had a connection object and just let you connect via the statement objects and reference counted the connections behind the scenes. But, too late for that now. I guess I'll just document that the connection object is only required to create the statements and doesn't have to stay around necessarily once you've created any statements you want to create.
So I guess I'm going to have to have the statement objects internally reference count their associated connection handles, so that it doesn't actually get destroyed until all the statements are destroyed that reference it, even if you destroy the connection object.
If I'd realized this, I probably wouldn't have even had a connection object and just let you connect via the statement objects and reference counted the connections behind the scenes. But, too late for that now. I guess I'll just document that the connection object is only required to create the statements and doesn't have to stay around necessarily once you've created any statements you want to create.
Dean Roddey
Explorans limites defectum
Explorans limites defectum