1 /*
2     Copyright (c) 2008-2009 NetAllied Systems GmbH
3 
4     This file is part of COLLADASaxFrameworkLoader.
5 
6     Licensed under the MIT Open Source License,
7     for details please see LICENSE file or the website
8     http://www.opensource.org/licenses/mit-license.php
9 */
10 
11 #ifndef __COLLADASAXFWL_HELPERLOADERBASE_H__
12 #define __COLLADASAXFWL_HELPERLOADERBASE_H__
13 
14 #include "COLLADASaxFWLPrerequisites.h"
15 
16 
17 namespace COLLADASaxFWL
18 {
19 	class FilePartLoader;
20 
21     /** This is the base class for all loader the load parts, that can appear in different libraries. */
22 	class HelperLoaderBase
23 	{
24 	private:
25 		/** The file part loader that handles the storage events. Usually the object itself.*/
26 		FilePartLoader* mHandlingFilePartLoader;
27 
28 	public:
HelperLoaderBase()29 		HelperLoaderBase(): mHandlingFilePartLoader( 0 ){}
~HelperLoaderBase()30 		virtual ~HelperLoaderBase(){}
31 
32 		/** Sets the handling FilePartLoader. You must set the handling FilePartLoader before the first sax callback
33 		is called*/
setHandlingFilePartLoader(FilePartLoader * handlingFilePartLoader)34 		void setHandlingFilePartLoader( FilePartLoader* handlingFilePartLoader ) { mHandlingFilePartLoader = handlingFilePartLoader; }
35 
36 		/** Returns the handling FilePartLoader. You must set the handling FilePartLoader before the first sax callback
37 		is called*/
getHandlingFilePartLoader()38 		FilePartLoader* getHandlingFilePartLoader() { COLLADABU_ASSERT(mHandlingFilePartLoader); return mHandlingFilePartLoader; }
39 
40 	private:
41 
42         /** Disable default copy ctor. */
43 		HelperLoaderBase( const HelperLoaderBase& pre );
44 
45         /** Disable default assignment operator. */
46 		const HelperLoaderBase& operator= ( const HelperLoaderBase& pre );
47 
48 	};
49 
50 } // namespace COLLADASAXFWL
51 
52 #endif // __COLLADASAXFWL_HELPERLOADERBASE_H__
53