/* -*- mode: c++; c-basic-offset: 4; indent-tabs-mode: nil -*- */ #ifndef IMAGE_LOADER_FACTORY_H #define IMAGE_LOADER_FACTORY_H #include #include class ImageLoaderImpl; class Image; class ImageLoader; class ImageLoaderFactory { public: void addLoaderImpl(const std::string& ext, ImageLoaderImpl *loaderImpl); ImageLoader *createLoader(const std::string& ext); static ImageLoaderFactory *getInstance(); protected : ImageLoaderFactory(); ~ImageLoaderFactory(); private: std::map _loaderImpls; static ImageLoaderFactory *_instance; }; #endif