traffic-generator/src/ModelRead.cpp
/**
 * Read in the flows probabilities to determine destinations for each message
 * type.
 *
 * @param modelFile The model file stream
 */
Read in the flows probabilities to determine destinations for each message
type.

@param modelFile The model file stream
Read in the flows probabilities to determine destinations for each message type . @param modelFile The model file stream
void ReadFlows2(ifstream& modelFile) {
	string header;
	int value, s, d, cl;
	modelFile >> header;
	while(!PeekForHeader(modelFile, "END")) {
		modelFile >> s >> d >> cl >> value;
		g_writeDest[g_hierClass][cl][s].Add(value);
	}
	modelFile >> header;
	modelFile >> header;
	while(!PeekForHeader(modelFile, "END")) {
		modelFile >> s >> d >> cl >> value;
		g_readDest[g_hierClass][cl][s].Add(value);
	}
	modelFile >> header;
	modelFile >> header;
	while(!PeekForHeader(modelFile, "END")) {
		modelFile >> s >> d >> cl >> value;
		g_ccrDest[g_hierClass][cl][s].Add(value);
	}
	modelFile >> header;
	modelFile >> header;
	while(!PeekForHeader(modelFile, "END")) {
		modelFile >> s >> d >> cl >> value;
		g_dcrDest[g_hierClass][cl][s].Add(value);
	}
	modelFile >> header;
}
void ReadFlows2 ( ifstream & modelFile ) { string header ; int value , s , d , cl ; modelFile >> header ; while ( ! PeekForHeader ( modelFile , " " ) ) { modelFile >> s >> d >> cl >> value ; g_writeDest [ g_hierClass ] [ cl ] [ s ] . Add ( value ) ; } modelFile >> header ; modelFile >> header ; while ( ! PeekForHeader ( modelFile , " " ) ) { modelFile >> s >> d >> cl >> value ; g_readDest [ g_hierClass ] [ cl ] [ s ] . Add ( value ) ; } modelFile >> header ; modelFile >> header ; while ( ! PeekForHeader ( modelFile , " " ) ) { modelFile >> s >> d >> cl >> value ; g_ccrDest [ g_hierClass ] [ cl ] [ s ] . Add ( value ) ; } modelFile >> header ; modelFile >> header ; while ( ! PeekForHeader ( modelFile , " " ) ) { modelFile >> s >> d >> cl >> value ; g_dcrDest [ g_hierClass ] [ cl ] [ s ] . Add ( value ) ; } modelFile >> header ; }
Read in the flows probabilities to determine destinations for each message
 type.
Read in the flows probabilities to determine destinations for each message type .