Example:
ifstream ricFile("E:\\RicCodeFile.txt");
string ricCode;
OmmArray ricArray;
// read RICS from file into Array
if (ricFile.is_open())
{
while (getline(ricFile, ricCode)) ricArray.addAscii(ricCode.c_str()); ricArray.complete();
ricFile.close();
}
// Encode array into ReqMsg
UInt64 handle = consumer.registerClient( ReqMsg() .serviceName( "IDN_SELECTFEED" ) .payload( ElementList().addArray( ":ItemList", ricArray ).complete() ).interestAfterRefresh(true), client );
---------------------------
Currently I am hard coding file path, service Name, but I want to make it configurable using config file. please help..