ns-allinone-2.35/ns-2.35/diffserv/dsPolicy.cc
void PolicyClassifier::updatePolicyRTT(int , const char*const* argv) {
  policyTableEntry *policy;
  
  policy = getPolicyTableEntry(atoi(argv[2]), atoi(argv[3]));
  if (policy == NULL)
    printf("ERROR: cannot update RTT; no existing policy found for Source %d-Desination %d.\n",
	   atoi(argv[2]), atoi(argv[3]));
  else {
    policy->winLen = (double) atof(argv[4]);
  }
}
/*-----------------------------------------------------------------------------
Pre: The command line specifies a source and destination node for which an
  RTT-Aware policy exists and a current RTT value for that policy.
Post: The aggRTT field of the appropriate policy is updated to a weighted
  average of the previous value and the new RTT value specified in the command
  line.  If no matching policy is found, an error message is printed.
-----------------------------------------------------------------------------*/
The command line specifies a source and destination node for which an
RTT-Aware policy exists and a current RTT value for that policy.
Post: The aggRTT field of the appropriate policy is updated to a weighted
average of the previous value and the new RTT value specified in the command
line.  If no matching policy is found, an error message is printed.
The command line specifies a source and destination node for which an RTT - Aware policy exists and a current RTT value for that policy . Post : The aggRTT field of the appropriate policy is updated to a weighted average of the previous value and the new RTT value specified in the command line . If no matching policy is found an error message is printed .
void PolicyClassifier::updatePolicyRTT(int , const char*const* argv) {
  policyTableEntry *policy;
  policy = getPolicyTableEntry(atoi(argv[2]), atoi(argv[3]));
  if (policy == NULL)
    printf("ERROR: cannot update RTT; no existing policy found for Source %d-Desination %d.\n",
	   atoi(argv[2]), atoi(argv[3]));
  else {
    policy->winLen = (double) atof(argv[4]);
  }
}
void PolicyClassifier :: updatePolicyRTT ( int , const char * const * argv ) { policyTableEntry * policy ; policy = getPolicyTableEntry ( atoi ( argv [ 2 ] ) , atoi ( argv [ 3 ] ) ) ; if ( policy == NULL ) printf ( " \n " , atoi ( argv [ 2 ] ) , atoi ( argv [ 3 ] ) ) ; else { policy -> winLen = ( double ) atof ( argv [ 4 ] ) ; } }
Pre: The command line specifies a source and destination node for which an
RTT-Aware policy exists and a current RTT value for that policy.
Pre : The command line specifies a source and destination node for which an RTT - Aware policy exists and a current RTT value for that policy .