Home || Visual Search || Applications || Architecture || Important Messages || OGL || Src

ImageRepository.h

Go to the documentation of this file.
00001 #ifndef Impala_Persistency_ImageRepository_h
00002 #define Impala_Persistency_ImageRepository_h
00003 
00004 #include "Persistency/RepositoryDispatcher.h"
00005 #include "Persistency/ImageRepositoryInFile.h"
00006 #include "Persistency/RepositoryNotImplemented.h"
00007 
00008 namespace Impala
00009 {
00010 namespace Persistency
00011 {
00012 
00013 
00014 class ImageRepository
00015     : public RepositoryDispatcher<ImageLocator,
00016                                   Core::Array::Array2dVec3UInt8,
00017                                   ImageRepositoryInFile,
00018                                   RepositoryNotImplemented<Core::Array::Array2dVec3UInt8> >
00019 {
00020 public:
00021 
00022     Core::Array::Array2dScalarUInt8*
00023     GetImageData(const ImageLocator& loc)
00024     {
00025         String protocol = loc.GetProtocol();
00026         if ((protocol == "file") || (protocol == "dataServer"))
00027         {
00028             return mRepFile.GetImageData(loc);
00029         }
00030         /*
00031         if (protocol == "mapi")
00032         {
00033             return mRepMonet.GetImageData(loc);
00034         }
00035         */
00036         ILOG_ERROR("GetImageData: unknown protocol: [" << loc.GetProtocol() <<
00037                    "] in " << loc);
00038         return 0;
00039     }
00040 
00041     ILOG_VAR_DEC;
00042 
00043 };
00044 
00045 ILOG_VAR_INIT(ImageRepository, Impala.Persistency);
00046 
00047 } // namespace Persistency
00048 } // namespace Impala
00049 
00050 #endif

Generated on Thu Jan 13 09:05:06 2011 for ImpalaSrc by  doxygen 1.5.1