Home | History | Annotate | Download | only in dae
      1 /*
      2 * Copyright 2006 Sony Computer Entertainment Inc.
      3 *
      4 * Licensed under the MIT Open Source License, for details please see license.txt or the website
      5 * http://www.opensource.org/licenses/mit-license.php
      6 *
      7 */
      8 
      9 #include <dae/daeErrorHandler.h>
     10 #include <modules/stdErrPlugin.h>
     11 
     12 daeErrorHandler *daeErrorHandler::_instance = NULL;
     13 std::auto_ptr<daeErrorHandler> daeErrorHandler::_defaultInstance(new stdErrPlugin);
     14 
     15 daeErrorHandler::daeErrorHandler() {
     16 }
     17 
     18 daeErrorHandler::~daeErrorHandler() {
     19 }
     20 
     21 void daeErrorHandler::setErrorHandler( daeErrorHandler *eh ) {
     22 	_instance = eh;
     23 }
     24 
     25 daeErrorHandler *daeErrorHandler::get() {
     26 	if ( _instance == NULL ) {
     27 		return _defaultInstance.get();
     28 	}
     29 	return _instance;
     30 }
     31