#include <Iconf.h>
Definition at line 39 of file Iconf.h.
AJP13::net_alhem_1_0_server::Security::Security | ( | ) |
AJP13::net_alhem_1_0_server::Security::Security | ( | const Xml::XmlNode & | it | ) |
virtual AJP13::net_alhem_1_0_server::Security::~Security | ( | ) | [inline, virtual] |
void AJP13::net_alhem_1_0_server::Security::FromXml | ( | const Xml::XmlNode & | it | ) |
Definition at line 51 of file Iconf.cpp.
References _element_authorization, _element_basicAuthentication, _element_group, AJP13::net_alhem_1_0_server::Security::Authorization_t::FromXml(), and AJP13::net_alhem_1_0_server::Security::BasicAuthentication_t::FromXml().
Referenced by AJP13::net_alhem_1_0_server::Configuration_t::FromXml(), and Security().
00052 { 00053 { 00054 Xml::XmlNode n(it, "group"); 00055 while (n) 00056 { 00057 net_alhem_1_0_server::Security::Group_t tmp(n); 00058 _element_group.push_back( tmp ); 00059 ++n; 00060 } 00061 } 00062 if (!it.Exists("basicAuthentication")) 00063 throw Xml::XmlException("missing required node in element 'security': basicAuthentication"); 00064 { 00065 Xml::XmlNode n(it, "basicAuthentication"); 00066 if (n) 00067 _element_basicAuthentication.FromXml( n ); 00068 } 00069 if (!it.Exists("authorization")) 00070 throw Xml::XmlException("missing required node in element 'security': authorization"); 00071 { 00072 Xml::XmlNode n(it, "authorization"); 00073 if (n) 00074 _element_authorization.FromXml( n ); 00075 } 00076 }
const std::string AJP13::net_alhem_1_0_server::Security::ToString | ( | const std::string & | name = "" |
) | const |
Definition at line 80 of file Iconf.cpp.
References _element_authorization, _element_basicAuthentication, _element_group, AJP13::net_alhem_1_0_server::Security::Authorization_t::ToString(), AJP13::net_alhem_1_0_server::Security::BasicAuthentication_t::ToString(), and AJP13::net_alhem_1_0_server::Security::Group_t::ToString().
Referenced by AJP13::net_alhem_1_0_server::Configuration_t::ToString().
00081 { 00082 std::string r; 00083 if (!name.empty()) 00084 r += "<" + name + ">"; 00085 for (std::list<net_alhem_1_0_server::Security::Group_t>::const_iterator it = _element_group.begin(); it != _element_group.end(); it++) 00086 { 00087 const net_alhem_1_0_server::Security::Group_t& ref = *it; 00088 r += ref.ToString("group"); 00089 } 00090 r += _element_basicAuthentication.ToString("basicAuthentication"); 00091 r += _element_authorization.ToString("authorization"); 00092 if (!name.empty()) 00093 r += "</" + name + ">"; 00094 return r; 00095 }
bool AJP13::net_alhem_1_0_server::Security::IsSet | ( | ) | const |
Definition at line 99 of file Iconf.cpp.
References AuthorizationIsSet(), BasicAuthenticationIsSet(), and GroupIsSet().
Referenced by AJP13::net_alhem_1_0_server::Configuration_t::SecurityIsSet().
00100 { 00101 return GroupIsSet() || BasicAuthenticationIsSet() || AuthorizationIsSet(); 00102 }
const std::list< net_alhem_1_0_server::Security::Group_t > & AJP13::net_alhem_1_0_server::Security::GetGroup | ( | ) | const |
Definition at line 106 of file Iconf.cpp.
References _element_group.
00107 { 00108 return _element_group; 00109 }
std::list< net_alhem_1_0_server::Security::Group_t > & AJP13::net_alhem_1_0_server::Security::GetGroup | ( | ) |
Definition at line 112 of file Iconf.cpp.
References _element_group.
00113 { 00114 return _element_group; 00115 }
void AJP13::net_alhem_1_0_server::Security::SetGroup | ( | const std::list< net_alhem_1_0_server::Security::Group_t > & | group | ) |
Definition at line 118 of file Iconf.cpp.
References _element_group.
00119 { 00120 _element_group = group; 00121 }
const net_alhem_1_0_server::Security::BasicAuthentication_t & AJP13::net_alhem_1_0_server::Security::GetBasicAuthentication | ( | ) | const |
Definition at line 125 of file Iconf.cpp.
References _element_basicAuthentication.
00126 { 00127 return _element_basicAuthentication; 00128 }
net_alhem_1_0_server::Security::BasicAuthentication_t & AJP13::net_alhem_1_0_server::Security::GetBasicAuthentication | ( | ) |
Definition at line 131 of file Iconf.cpp.
References _element_basicAuthentication.
00132 { 00133 return _element_basicAuthentication; 00134 }
void AJP13::net_alhem_1_0_server::Security::SetBasicAuthentication | ( | const net_alhem_1_0_server::Security::BasicAuthentication_t & | basicAuthentication | ) |
Definition at line 137 of file Iconf.cpp.
References _element_basicAuthentication.
00138 { 00139 _element_basicAuthentication = basicAuthentication; 00140 }
const net_alhem_1_0_server::Security::Authorization_t & AJP13::net_alhem_1_0_server::Security::GetAuthorization | ( | ) | const |
Definition at line 144 of file Iconf.cpp.
References _element_authorization.
00145 { 00146 return _element_authorization; 00147 }
net_alhem_1_0_server::Security::Authorization_t & AJP13::net_alhem_1_0_server::Security::GetAuthorization | ( | ) |
Definition at line 150 of file Iconf.cpp.
References _element_authorization.
00151 { 00152 return _element_authorization; 00153 }
void AJP13::net_alhem_1_0_server::Security::SetAuthorization | ( | const net_alhem_1_0_server::Security::Authorization_t & | authorization | ) |
Definition at line 156 of file Iconf.cpp.
References _element_authorization.
00157 { 00158 _element_authorization = authorization; 00159 }
bool AJP13::net_alhem_1_0_server::Security::GroupIsSet | ( | ) | const |
Definition at line 163 of file Iconf.cpp.
References _element_group.
Referenced by IsSet().
00164 { 00165 return !_element_group.empty(); 00166 }
bool AJP13::net_alhem_1_0_server::Security::BasicAuthenticationIsSet | ( | ) | const |
Definition at line 170 of file Iconf.cpp.
References _element_basicAuthentication, and AJP13::net_alhem_1_0_server::Security::BasicAuthentication_t::IsSet().
Referenced by IsSet().
00171 { 00172 return _element_basicAuthentication.IsSet(); 00173 }
bool AJP13::net_alhem_1_0_server::Security::AuthorizationIsSet | ( | ) | const |
Definition at line 177 of file Iconf.cpp.
References _element_authorization, and AJP13::net_alhem_1_0_server::Security::Authorization_t::IsSet().
Referenced by IsSet().
00178 { 00179 return _element_authorization.IsSet(); 00180 }
std::list<net_alhem_1_0_server::Security::Group_t> AJP13::net_alhem_1_0_server::Security::_element_group [private] |
Definition at line 205 of file Iconf.h.
Referenced by FromXml(), GetGroup(), GroupIsSet(), SetGroup(), and ToString().
net_alhem_1_0_server::Security::BasicAuthentication_t AJP13::net_alhem_1_0_server::Security::_element_basicAuthentication [private] |
Definition at line 206 of file Iconf.h.
Referenced by BasicAuthenticationIsSet(), FromXml(), GetBasicAuthentication(), SetBasicAuthentication(), and ToString().
net_alhem_1_0_server::Security::Authorization_t AJP13::net_alhem_1_0_server::Security::_element_authorization [private] |
Definition at line 207 of file Iconf.h.
Referenced by AuthorizationIsSet(), FromXml(), GetAuthorization(), SetAuthorization(), and ToString().