Printing data to a stream
Shows how to print your data to a stream, using the .dat file syntax.
As an additional service for testing and debugging, the class IloOplModel offers the possibility to print all the data to a stream, using the .dat file syntax.
C++
IloOplModel::printExternalData(ostream&)
Java
IloOplModel.printExternalData(java.io.OutputStream outs)
.NET (C#)
OplModel.PrintExternalData(TextWriter outs)
If your model uses data from various sources, like databases, spreadsheets, or custom sources, you will be able to write this data to one single file, which makes it easier to read. This file can be used as a data source for other model instances.
For debugging purposes, you can visualize intermediate data, that is, the data that is not provided by data sources but calculated during preprocessing.
C++
IloOplModel::printInternalData(ostream&)
Java
IloOplModel.printInternalData(java.io.OutputStream outs)
.NET (C#)
OplModel.PrintInternalData(TextWriter outs)