}
}
+/** @brief try to reconnect the current connection with the same connection credentials (host and port or path)
+*/
+void socket_client_connection::reconnect()
+{
+ // close the current connection if still open
+ close();
+
+ socket_type_value type=get_type();
+
+ if (type == tcp_s)
+ tcp_connect(max_retries);
+ else if (type == unix_s)
+ unix_connect(max_retries);
+
+ reopen();
+}
+
}