Class ResultTable

java.lang.Object
org.sblim.slp.internal.ua.ResultTable
All Implemented Interfaces:
java.util.Iterator<java.lang.Object>

public class ResultTable extends java.lang.Object implements java.util.Iterator<java.lang.Object>
ResultTable
  • Constructor Details

    • ResultTable

      public ResultTable()
  • Method Details

    • registerRequester

      public void registerRequester(DatagramRequester pReq)
      ResultTable has to know which Requesters provide results. Requester have to be registered before hasNext() is called.
      Parameters:
      pReq -
      See Also:
    • unregisterRequester

      public void unregisterRequester(DatagramRequester pReq)
      If the Requester's sequence is completed, Requester has to be unregistered otherwise hasNext() will block.
      Parameters:
      pReq -
    • addResults

      public void addResults(ReplyMessage pReplyMsg)
      addResults
      Parameters:
      pReplyMsg -
    • addResults

      public void addResults(java.util.Iterator<?> pResItr)
      addResults
      Parameters:
      pResItr -
    • addExceptions

      public void addExceptions(ReplyMessage pReplyMsg)
      addExceptions
      Parameters:
      pReplyMsg -
    • addExceptions

      public void addExceptions(java.util.Iterator<?> pExceptionItr)
      addExceptions
      Parameters:
      pExceptionItr -
    • addException

      public void addException(java.lang.Exception pE)
      addException
      Parameters:
      pE -
    • getTotalResponses

      public int getTotalResponses()
      getTotalResponses
      Returns:
      int
    • hasNext

      public boolean hasNext()
      Specified by:
      hasNext in interface java.util.Iterator<java.lang.Object>
      Returns:
      true if there are results or exceptions to read
      See Also:
      • Iterator.hasNext()
    • next

      public java.lang.Object next() throws java.util.NoSuchElementException
      Specified by:
      next in interface java.util.Iterator<java.lang.Object>
      Returns:
      a result or an Exception
      Throws:
      java.util.NoSuchElementException
      See Also:
      • Iterator.next()
    • nextException

      public java.lang.Object nextException() throws java.util.NoSuchElementException
      Returns:
      next element in Exception table
      Throws:
      java.util.NoSuchElementException
    • hasMoreExceptions

      public boolean hasMoreExceptions()
      Returns:
      next element in Exception table
    • remove

      public void remove()
      Specified by:
      remove in interface java.util.Iterator<java.lang.Object>