added sanity checks and toString() override
added global reference and database manipulators
added debugger frame