AbstractMessageListener
- java.lang.Object
-
- com.dashoptimization.AbstractMessageListener
-
- All Implemented Interfaces:
- XPRSmessageListener, java.util.EventListener
- Direct Known Subclasses:
- DefaultMessageListener, EmptyMessageListener
public abstract class AbstractMessageListener extends java.lang.Object implements XPRSmessageListener
Message handler. This class is an implementation ofXPRSmessageListenerthat provides a more explicit interface for message passing. Users need to subclass this class and provide implementations forinfoMessage(XPRSprob,String),warningMessage(XPRSprob,String)anderrorMessage(XPRSprob,String). They may also overrideflush(XPRSprob)to react to explicit flushing requests.
-
-
Constructor Summary
Constructor and Description AbstractMessageListener()
-
Method Summary
Modifier and Type Method and Description voidXPRSmessageEvent(XPRSprob prob, java.lang.Object vContext, java.lang.String msg, int len, int msgtype)Implement function required byXPRSmessageListenerinterface.
-
-
-
Method Detail
-
XPRSmessageEvent
public final void XPRSmessageEvent(XPRSprob prob, java.lang.Object vContext, java.lang.String msg, int len, int msgtype)
Implement function required byXPRSmessageListenerinterface. This function forwards the message to one of the appropriate handlersinfoMessage(XPRSprob,String),warningMessage(XPRSprob,String)orerrorMessage(XPRSprob,String).- Specified by:
-
XPRSmessageEventin interfaceXPRSmessageListener - Parameters:
-
prob- The problem for which the handler is invoked. -
vContext- The object that was registered withXPRSprob.addMessageListener(XPRSmessageListener,Object). Note that this is not forwarded to the message handling functions. Any callback-specific data should be implemented as a member of the subclass. -
msg- The message. -
len- The length ofmsg. Since this is redundant information, it is not forwarded to the message handling functions. -
msgtype- The type of the message. This is used to figure out which of the message handling functions to call.
-
-
© 2001-2023 Fair Isaac Corporation. All rights reserved. This documentation is the property of Fair Isaac Corporation (“FICO”). Receipt or possession of this documentation does not convey rights to disclose, reproduce, make derivative works, use, or allow others to use it except solely for internal evaluation purposes to determine whether to purchase a license to the software described in this documentation, or as otherwise set forth in a written software license agreement between you and FICO (or a FICO affiliate). Use of this documentation and the software described in it must conform strictly to the foregoing permitted uses, and no other use is permitted.
