00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011 #ifndef EDGReplicaManager_InfoService_H
00012 #define EDGReplicaManager_InfoService_H 1
00013
00014
00015
00016
00017
00018
00019 #include <string>
00020 #include <vector>
00021
00022 #include "EdgReplicaManager/ReplicaManagerExceptions.h"
00023
00024 namespace EdgReplicaManager {
00025
00027 class InfoService {
00028 public:
00029
00033 InfoService(const std::string &vo, bool secure);
00034
00037 virtual ~InfoService() {}
00038
00043 std::string getLocalReplicaCatalogLocation(const std::string &domain) throw(InfoServiceException);
00044
00049 std::string getMetadataCatalogLocation(const std::string &domain) throw(InfoServiceException);
00050
00054 std::string getReplicaOptimizationLocation(const std::string &domain) throw(InfoServiceException);
00055
00059 std::string getServiceURI(const std::string &serviceType, const std::string &domain)
00060 throw(InfoServiceException);
00061
00063 virtual std::string getCloseSE(const std::string& ceID) throw ( InfoServiceException ) = 0;
00064
00065 bool isSecure() {
00066 return m_secure;
00067 }
00068 protected:
00069
00070 virtual const std::vector<std::string>& getServiceURIs(const std::string &serviceType,
00071 const std::string &domain)
00072 throw(InfoServiceException) =0;
00073
00074
00075 bool isLRC(const std::string &type);
00076 bool isRMC(const std::string &type);
00077 bool isROS(const std::string &type);
00078
00079 std::string m_lrcURI;
00080 std::string m_rmcURI;
00081 std::string m_rosURI;
00082 std::string m_vo;
00083 bool m_secure;
00084 };
00085
00086 };
00087
00088 #endif