02-04-2008, 06:15 PM
|
#1 (permalink)
|
|
The Addict
Join Date: Jan 2008
Location: USA
Posts: 217
Thanks: 16
|
"Singleton" Error Queue?
I was working and thinking, as per usual, and figured it might be a handy thing to implement a type that acted as a singleton where I could put a bunch of non-fatal errors into. This way I can have a stack of debug messages and handle them however I want, without try/except. This is for things like query errors, object initialization faults, and the like. Obviously in a finished product the last thing you want is a die statement triggering, and a client wondering how to get back.
Any suggestions for how I could set an object such as this up? Or should I even use an object? I just came up with this recently, so I figured I'd get input on this.
__________________
Programmers are in a race with the Universe to create bigger and better idiot-proof programs, while the Universe is trying to create bigger and better idiots. So far the Universe is winning. - Rich Cook
|
|
|
|