Class PollDataSource

java.lang.Object
com.verisign.epp.serverstub.PollDataSource
All Implemented Interfaces:
EPPPollDataSource

public class PollDataSource extends Object implements EPPPollDataSource
The <PollDataSource> is registered and used by EPPPollQueueMgr to demostrate how data are stored into a queue. The data source can be files, databases or others.

  • Constructor Details

    • PollDataSource

      public PollDataSource()
  • Method Details

    • get

      public EPPPollDataRecord get(Object aRecp, Object aContextData) throws EPPPollQueueException
      Gets data from queue
      Specified by:
      get in interface EPPPollDataSource
      Parameters:
      aRecp - Receipt message queue. Not used by the Server Stub.
      aContextData - Server specific data that is passed through to the data source (i.e. database connection). Not used by the Server Stub.
      Returns:
      EPPPollDataRecord if exists; null otherwise.
      Throws:
      EPPPollQueueException - Error getting message from queue
    • put

      public void put(Object aRecp, String aKind, Object aData, Object aContextData)
      Puts data into queue
      Specified by:
      put in interface EPPPollDataSource
      Parameters:
      aRecp - Message recipient. Not used in Server Stub.
      aKind - The type of response data
      aData - Message data to put in queue
      aContextData - Server specific data that is passed through to the data source (i.e. database connection). Not used by the Server Stub.
    • delete

      public int delete(Object aRecp, String aMsgId, Object aContextData) throws EPPPollQueueException
      Delete data from data source and return number of messages
      Specified by:
      delete in interface EPPPollDataSource
      Parameters:
      aRecp - Recipient queue. Not used in Server Stub.
      aMsgId - Message to delete. Not used in Server Stub, since the Server Stub will delete the top message of queue
      aContextData - Server specific data that is passed through to the data source (i.e. database connection). Not used by the Server Stub.
      Returns:
      int Number of messages left in queue
      Throws:
      EPPPollQueueException - Error deleting message