}
void comm::CongestionController::setLimit(const int limit)
-throw() {
+{
Guard guard(a_mutex, "comm::CongestionController (setLimit)");
if(limit < 0 || limit > 100) {
}
void comm::CongestionController::setMaxPendingBytes(const int maxPendingBytes)
-throw(RuntimeException) {
+noexcept(false) {
if(maxPendingBytes == UnusedPendingBytes) {
a_maxPendingBytes = UnusedPendingBytes;
return;
* por su manejador asociado.
*/
comm::CongestionController::Advice::_v comm::CongestionController::getAdvice(const ClientSocket& clientSocket)
-throw() {
+{
Guard guard(a_mutex, "comm::CongestionController::getAdvice");
if(a_limit == 0) {
}
void comm::CongestionController::incrementIncomingSocket()
-throw(RuntimeException) {
+noexcept(false) {
Guard guard(a_mutex, "comm::CongestionController::incrementIncomingSocket");
a_incomingSocketCounter ++;
}
void comm::CongestionController::decrementIncomingSocket()
-throw(RuntimeException) {
+noexcept(false) {
if(a_incomingSocketCounter == 0)
return;
}
int comm::CongestionController::calculeWorkload(const ClientSocket& clientSocket) const
-throw() {
+{
int maxSize;
if(a_maxPendingBytes == UnusedPendingBytes)
}
xml::Node* comm::CongestionController::asXML(xml::Node* parent) const
-throw() {
+{
static const char* modetxt [] = { "Auto", "Local", "Global" };
xml::Node* result = parent->createChild("comm.CongestionController");
result->createAttribute("Limit", a_limit);
}
comm::CongestionController::Workload comm::CongestionController::getAccumulatedWorkload() const
-throw() {
+{
Workload result;
const Millisecond now = functions::millisecond();
comm::CongestionController::Workload comm::CongestionController::getCurrentWorkload(const comm::ClientSocket& clientSocket) const
-throw() {
+{
Workload result;
result.second = calculeWorkload(clientSocket);