changed to eliniate runtime exception
Interface definition for error processing callbacks
Default error call back implementation
Extended to add error callback functions so error processing can be
adapted without modifing the main implimentation.