00001 #ifndef Fireworks_Core_FWJobMetadataManager 00002 #define Fireworks_Core_FWJobMetadataManager 00003 00004 #include "Fireworks/Core/interface/FWTypeToRepresentations.h" 00005 00006 #include "sigc++/signal.h" 00007 00008 #include <string> 00009 #include <vector> 00010 00011 class FWJobMetadataUpdateRequest; 00012 class FWTypeToRepresentations; 00013 00018 class FWJobMetadataManager 00019 { 00020 public: 00021 struct Data 00022 { 00023 std::string purpose_; 00024 std::string type_; 00025 std::string moduleLabel_; 00026 std::string productInstanceLabel_; 00027 std::string processName_; 00028 }; 00029 00030 FWJobMetadataManager(); 00031 virtual ~FWJobMetadataManager(); 00032 00033 std::vector<Data> &usableData() { return m_metadata; } 00034 std::vector<std::string> &processNamesInJob() { return m_processNamesInJob; } 00035 00046 void update(FWJobMetadataUpdateRequest *request); 00047 00051 void initReps(const FWTypeToRepresentations& iTypeAndReps); 00052 00053 sigc::signal<void> metadataChanged_; 00054 protected: 00060 virtual bool doUpdate(FWJobMetadataUpdateRequest *) = 0; 00061 std::vector<Data> m_metadata; 00062 std::vector<std::string> m_processNamesInJob; 00063 FWTypeToRepresentations *m_typeAndReps; 00064 }; 00065 00066 #endif