Interface DataSender

All Superinterfaces:
AutoCloseable, Closeable
All Known Implementing Classes:
DataSenderImpl

public interface DataSender extends Closeable
An interface of a class sending data to a queue.
Author:
Michael Röder (roeder@informatik.uni-leipzig.de)
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    A blocking method that closes the sender when its work is done, i.e., all messages have been consumed by receivers from the queue.
    void
    sendData(byte[] data)
    Send the given data to the queue.

    Methods inherited from interface java.io.Closeable

    close
  • Method Details

    • sendData

      void sendData(byte[] data) throws IOException
      Send the given data to the queue.
      Parameters:
      data - the data that should be sent
      Throws:
      IOException - if an exception occurs during the communication with the queue
    • closeWhenFinished

      void closeWhenFinished()
      A blocking method that closes the sender when its work is done, i.e., all messages have been consumed by receivers from the queue.