com.devexperts.qd.qtp
Interface MessageProvider

All Known Implementing Classes:
AgentAdapter, DistributorAdapter, MessageAdapter

public interface MessageProvider

The MessageProvider provides QTP messages. It shall be implemented by an agent of some entity to be used by standard QTP connectors. Its methods are invoked when QTP connector is ready to send some messages, usually from threads allocated internally by used QTP connector.


Method Summary
 boolean retrieveMessages(MessageVisitor visitor)
          Retrieves accumulated message into specified message visitor.
 void setMessageListener(MessageListener listener)
          Sets new message listener to receive notifications about messages.
 

Method Detail

retrieveMessages

boolean retrieveMessages(MessageVisitor visitor)
Retrieves accumulated message into specified message visitor. Returns true if some messages still remains in the provider or false if all accumulated messages were retrieved.


setMessageListener

void setMessageListener(MessageListener listener)
Sets new message listener to receive notifications about messages. Only one listener at a time is supported; the former listener is discarded. Use null to set empty message listener (no notifications).

NOTE: if there is accumulated data available, then specified listener will be notified by this method.