|
Gaudi Framework, version v21r7 |
| Home | Generated: 22 Jan 2010 |
#include <Catalogue.h>

Definition at line 98 of file Catalogue.h.
| Gaudi::Parsers::PropertyEntry::PropertyEntry | ( | ) | [inline] |
| Gaudi::Parsers::PropertyEntry::PropertyEntry | ( | const std::string & | name, | |
| const std::string & | value | |||
| ) |
Constructor.
| name | Name of property | |
| value | String value of property. |
Definition at line 26 of file PropertyEntry.cpp.
| Gaudi::Parsers::PropertyEntry::PropertyEntry | ( | const std::string & | name, | |
| const std::vector< std::string > & | value | |||
| ) |
Creator.
| name | Name of property | |
| value | Vector value of property |
Definition at line 42 of file PropertyEntry.cpp.
00044 { 00045 m_name = name; 00046 m_value = value; 00047 m_isVector = true; 00048 if ( 1 == m_value.size() && "" == m_value[0] ) { clear(); } 00049 }
| Gaudi::Parsers::PropertyEntry::PropertyEntry | ( | const std::string & | name, | |
| const std::string & | value, | |||
| const Position & | pos | |||
| ) |
Constructor.
| name | Name of property | |
| value | String value of property. | |
| pos | Property position in file |
Definition at line 60 of file PropertyEntry.cpp.
00063 { 00064 m_name = name; 00065 m_value.push_back(value); 00066 m_position = pos; 00067 m_isVector = false; 00068 }
| Gaudi::Parsers::PropertyEntry::PropertyEntry | ( | const std::string & | name, | |
| const std::vector< std::string > & | value, | |||
| const Position & | pos | |||
| ) |
Creator.
| name | Name of property | |
| value | Vector value of property | |
| pos | Property position in file |
Definition at line 80 of file PropertyEntry.cpp.
00083 { 00084 m_name = name; 00085 m_value = value; 00086 m_position = pos; 00087 m_isVector = true; 00088 if ( 1 == m_value.size() && "" == m_value[0] ) { clear(); } 00089 }
| const std::string& Gaudi::Parsers::PropertyEntry::name | ( | void | ) | const [inline] |
Name of property.
Definition at line 134 of file Catalogue.h.
00134 {return m_name;};
| void Gaudi::Parsers::PropertyEntry::setName | ( | const std::string & | name | ) | [inline] |
| std::string Gaudi::Parsers::PropertyEntry::value | ( | void | ) | const |
Value of property.
Definition at line 96 of file PropertyEntry.cpp.
00097 { 00098 std::string result=""; 00099 if(m_isVector){ 00100 result = "["; 00101 std::string delim=""; 00102 for(std::vector<std::string>::const_iterator cur=m_value.begin(); 00103 cur!=m_value.end();cur++){ 00104 result+=delim+*cur; 00105 delim=","; 00106 } 00107 result+="]"; 00108 }else{ 00109 if(m_value.size()>0){ 00110 result = m_value[0]; 00111 } 00112 } 00113 return result; 00114 }
| Position Gaudi::Parsers::PropertyEntry::position | ( | void | ) | const [inline] |
| StatusCode Gaudi::Parsers::PropertyEntry::addValues | ( | const std::vector< std::string > & | values | ) |
Add values to vector value.
| values | Values to add |
Definition at line 125 of file PropertyEntry.cpp.
00126 { 00127 if(!m_isVector) return StatusCode::FAILURE; 00128 for(std::vector<std::string>::const_iterator cur = values.begin(); 00129 cur!=values.end();cur++){ 00130 m_value.push_back(*cur); 00131 } 00132 return StatusCode::SUCCESS; 00133 }
| StatusCode Gaudi::Parsers::PropertyEntry::removeValues | ( | const std::vector< std::string > & | values, | |
| int & | count | |||
| ) |
Remove values from property value.
| values | ||
| count | Count of removed items |
Definition at line 145 of file PropertyEntry.cpp.
00147 { 00148 if(!m_isVector) return StatusCode::FAILURE; 00149 for(std::vector<std::string>::const_iterator 00150 cur = values.begin();cur!=values.end();cur++){ 00151 std::vector<std::string>::iterator item = std::find(m_value.begin(), 00152 m_value.end(),*cur); 00153 if(item!=m_value.end()){ 00154 m_value.erase(item); 00155 count++; 00156 } 00157 } 00158 return StatusCode::SUCCESS; 00159 }
| StatusCode Gaudi::Parsers::PropertyEntry::clear | ( | void | ) |
Clear property vector value.
Definition at line 167 of file PropertyEntry.cpp.
00168 { 00169 if(!m_isVector) return StatusCode::FAILURE; 00170 m_value.clear(); 00171 return StatusCode::SUCCESS; 00172 }
| StatusCode Gaudi::Parsers::PropertyEntry::removeEnv | ( | ) |
remove environment variables
Definition at line 176 of file PropertyEntry.cpp.
00177 { 00178 for ( std::vector<std::string>::iterator item = 00179 m_value.begin() ; m_value.end() != item ; ++item ) 00180 { *item = Gaudi::Parsers::Utils::removeEnvironment ( *item ) ; } 00181 return StatusCode::SUCCESS ; 00182 }
Definition at line 173 of file Catalogue.h.
std::vector<std::string> Gaudi::Parsers::PropertyEntry::m_value [private] |
Definition at line 174 of file Catalogue.h.
Position Gaudi::Parsers::PropertyEntry::m_position [private] |
Definition at line 175 of file Catalogue.h.
bool Gaudi::Parsers::PropertyEntry::m_isVector [private] |
Definition at line 176 of file Catalogue.h.