00001 #ifndef Impala_Persistency_FeatureListRepository_h 00002 #define Impala_Persistency_FeatureListRepository_h 00003 00004 #include "Persistency/RepositoryDispatcher.h" 00005 #include "Persistency/FeatureListRepositoryInFile.h" 00006 #include "Persistency/RepositoryNotImplemented.h" 00007 00008 namespace Impala 00009 { 00010 namespace Persistency 00011 { 00012 00013 00014 class FeatureListRepository 00015 : public RepositoryDispatcher<FeatureLocator, 00016 Core::Feature::FeatureList, 00017 FeatureListRepositoryInFile, 00018 RepositoryNotImplemented<Core::Feature::FeatureList> > 00019 { 00020 public: 00021 00022 bool 00023 Exists(const FeatureLocator& loc) 00024 { 00025 String protocol = loc.GetProtocol(); 00026 if ((protocol == "file") || (protocol == "dataServer")) 00027 { 00028 return mRepFile.Exists(loc); 00029 } 00030 ILOG_ERROR("Get: unknown protocol: [" << loc.GetProtocol() << "] in " 00031 << loc); 00032 return false; 00033 } 00034 00035 }; 00036 00037 } // namespace Persistency 00038 } // namespace Impala 00039 00040 #endif