Would it be possible to extend the API to add an isClosed method to the Geodatabase and Table classes. Also isWriteLocked and isLoadOnlyMode on Table would be useful.
At the moment applications have to implement some other kind of reference counting to make sure they don't access closed geodatabases or tables or track if a table is locked or in load only mode.
Trying to access closed geodatabase or tables causes a core dump rather than throwing some kind of exception or error code. This makes developing applications tricky as apps just crash rather than getting a nice 'This object is closed' type message.