// Se invoca desde el ldap::Engine
//---------------------------------------------------------------------------------
void Session::bind()
-throw(RuntimeException) {
+noexcept(false) {
if(a_state != State::Closed)
return;
}
const Response* Session::send(const Request* request)
-throw(RuntimeException) {
+noexcept(false) {
if(a_state == State::Closed) {
string msg(asString());
msg += " | Session::bind must be called";
}
void Session::unbind()
-throw(RuntimeException) {
+noexcept(false) {
if(a_state == State::Closed)
return;
// a la ldap::Session
//------------------------------------------------------------------------------------------
void Session::apply()
-throw(RuntimeException) {
+noexcept(false) {
LOGMETHOD(TraceMethod traceMethod("ldap::Session", "apply", ANNA_FILE_LOCATION));
LDAP* handle = (LDAP*) a_ldap;
LDAPMessage* hmessage(NULL);
* invocado por el comm::Communicator::detach.
*/
void Session::finalize()
-throw() {
+{
LDAP* handle = (LDAP*) a_ldap;
a_state = State::Closed;
}
void Session::receiveBind(const IdMessage idMessage, Session::HandleMessage _hmessage)
-throw(RuntimeException) {
+noexcept(false) {
LDAP* handle = (LDAP*) a_ldap;
LDAPMessage* hmessage = (LDAPMessage*) _hmessage;
// (1) Necesario para detectar el final de los atributos
//------------------------------------------------------------------------------------------------
void Session::receiveEntry(const IdMessage idMessage, Session::HandleMessage _hmessage)
-throw(RuntimeException) {
+noexcept(false) {
LDAP* handle = (LDAP*) a_ldap;
LDAPMessage* hmessage = (LDAPMessage*) _hmessage;
BerElement *ber(NULL);
}
void Session::receiveReference(const IdMessage idMessage, Session::HandleMessage _hmessage)
-throw(RuntimeException) {
+noexcept(false) {
LDAP* handle = (LDAP*) a_ldap;
LDAPMessage* hmessage = (LDAPMessage*) _hmessage;
char **values(NULL);
}
void Session::receiveResult(const IdMessage idMessage, Session::HandleMessage _hmessage)
-throw(RuntimeException) {
+noexcept(false) {
LDAP* handle = (LDAP*) a_ldap;
LDAPMessage* hmessage = (LDAPMessage*) _hmessage;
Response* response = response_find(idMessage);
// Se invoca desde ldap::timer::Prototype::expire
//-------------------------------------------------------------------------
void Session::expireResponse(ldap::Response* response)
-throw() {
+{
LDAP* handle = (LDAP*) a_ldap;
ResultCode resultCode;
/*
}
void Session::response_add(Response* response)
-throw() {
+{
a_responses.add(response);
response->setSession(this);
}
void Session::response_erase(Response* response)
-throw() {
+{
a_responses.erase(response);
Response::release(response);
}
Response* Session::response_find(const IdMessage idMessage)
-throw(RuntimeException) {
+noexcept(false) {
ldap::Response* result = a_responses.find(idMessage);
if(result == NULL) {
}
std::string Session::asString() const
-throw() {
+{
string result("ldap::Session { ");
result += comm::Handler::asString();
result += " | State: ";
}
xml::Node* Session::asXML(xml::Node* parent) const
-throw() {
+{
parent = comm::Handler::asXML(parent);
xml::Node* result = parent->createChild("ldap.Session");
result->createAttribute("State", asText(a_state));
}
int Session::getDangerousFileDescriptor() const
-throw(RuntimeException) {
+noexcept(false) {
ResultCode resultCode;
int result = -1;
resultCode = ldap_get_option((LDAP*) a_ldap, LDAP_OPT_DESC, &result);
}
const char* Session::asText(const State::_v state)
-throw() {
+{
static const char* states [] = { "Closed", "WaitingBind", "Bound" };
return states [state];
}
IdMessage Session::SortById::value(const Response* response)
-throw() {
+{
return response->getIdMessage();
}