From 4b0e52aee0436c406febe9140a7853c867dcd7a1 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Michal=20Voc=C5=AF?= Date: Fri, 13 Apr 2007 14:04:52 +0000 Subject: [PATCH] * make getAttrName static method --- org.glite.lb.client-interface/interface/Event.h.T | 6 +++--- org.glite.lb.client-interface/interface/JobStatus.h.T | 2 +- org.glite.lb.client/src/Event.cpp.T | 3 +-- org.glite.lb.client/src/JobStatus.cpp.T | 2 +- 4 files changed, 6 insertions(+), 7 deletions(-) diff --git a/org.glite.lb.client-interface/interface/Event.h.T b/org.glite.lb.client-interface/interface/Event.h.T index 714a7c0..3e1d52b 100644 --- a/org.glite.lb.client-interface/interface/Event.h.T +++ b/org.glite.lb.client-interface/interface/Event.h.T @@ -222,10 +222,10 @@ public: * Retrieves string representation of the attribute name. * \param[in] name Symbolic name of the attribute. * \returns String name of the attribute. - * \throw Exception Invalid event type or attribute not - * defined for this event. + * \throw Exception Invalid attribute name. + * */ - const std::string & getAttrName(Attr name) const; + static const std::string & getAttrName(Attr name); /** List of attributes and types valid for this instance. * diff --git a/org.glite.lb.client-interface/interface/JobStatus.h.T b/org.glite.lb.client-interface/interface/JobStatus.h.T index f183a33..5acde1a 100644 --- a/org.glite.lb.client-interface/interface/JobStatus.h.T +++ b/org.glite.lb.client-interface/interface/JobStatus.h.T @@ -210,7 +210,7 @@ public: * \returns Name of attribute. * \throws LoggingException Invalid attribute name. */ - const std::string& getAttrName(Attr name) const; + static const std::string& getAttrName(Attr name); /** List of attributes and their types valid for this * instance. diff --git a/org.glite.lb.client/src/Event.cpp.T b/org.glite.lb.client/src/Event.cpp.T index 6e3ac3e..0402a80 100644 --- a/org.glite.lb.client/src/Event.cpp.T +++ b/org.glite.lb.client/src/Event.cpp.T @@ -269,9 +269,8 @@ std::string const attr_names[Event::ATTR_MAX] = { @@@} }; - const std::string & -Event::getAttrName(Attr attr) const +Event::getAttrName(Attr attr) { if (attr<0 || attr>=ATTR_MAX) { STACK_ADD; diff --git a/org.glite.lb.client/src/JobStatus.cpp.T b/org.glite.lb.client/src/JobStatus.cpp.T index df9609b..62559e0 100644 --- a/org.glite.lb.client/src/JobStatus.cpp.T +++ b/org.glite.lb.client/src/JobStatus.cpp.T @@ -414,7 +414,7 @@ static std::string const attr_names[JobStatus::ATTR_MAX] = { }; const std::string & -JobStatus::getAttrName(JobStatus::Attr attr) const +JobStatus::getAttrName(JobStatus::Attr attr) { if (attr<0 || attr>=ATTR_MAX) { STACK_ADD; -- 1.8.2.3