Handling Message Channels: Callable Library Routines

ILOG CPLEX defines several message channels for flexible control over message output:

Output messages flow through message channels to destinations. Message channels are associated with destinations through their destination list. Messages from routines of the ILOG CPLEX Callable Library are assigned internally to one of those predefined channels. Those default channels are C pointers to ILOG CPLEX objects; they are initialized by CPXopenCPLEX(); they are not global variables. Your application accesses these objects by calling the routine CPXgetchannels(). You can use these predefined message channels for your own application messages. You can also define new channels.

An application using routines from the ILOG CPLEX Callable Library produces no output messages unless the application specifies message handling instructions through one or more calls to the message handling routines of the Callable Library. In other words, the destination list of each channel is initially empty.

Messages from multiple channels may be sent to one destination. All predefined ILOG CPLEX channels can be directed to a single file by a call to CPXsetlogfile(). Similarly, all predefined ILOG CPLEX channels except cpxlog can be directed to the screen by CPX_PARAM_SCRIND. For a finer level of control, or to define destinations for application-specific messages, use the following message handling routines, all documented in the ILOG CPLEX Reference Manual:

Once channel destinations are established, messages can be sent to multiple destinations by a single call to a message-handling routine.

Figure 8.1 ILOG CPLEX Message Handling Routines


Previous Page: Handling Message Channels: the Output-Channel Parameter  Return to Top Next Page: Example: Using the Message Handler