Documentation of 'edu.rit.pj.cluster.Proxy' Java class
Proxy
edu.rit.pj.cluster

Class Proxy

    • Constructor Summary

      Constructors 
      Constructor and Description
      Proxy(ChannelGroup theChannelGroup, Channel theChannel)
      Construct a new proxy.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      void close()
      Close communication with this proxy's far end process.
      Status receive(Buf theDst)
      Receive a message from this proxy's far end process.
      Status receive(java.lang.Integer theTag, Buf theDst)
      Receive a message with the given tag from this proxy's far end process.
      void send(int theTag, Buf theSrc)
      Send a message with the given tag and items to this proxy's far end process.
      void send(Message theMessage)
      Send the given message to this proxy's far end process.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • Proxy

        public Proxy(ChannelGroup theChannelGroup,
                     Channel theChannel)
        Construct a new proxy. The proxy will use the given channel in the given channel group to send messages to the far end process.
        Parameters:
        theChannelGroup - Channel group.
        theChannel - Channel.
    • Method Detail

      • send

        public void send(Message theMessage)
                  throws java.io.IOException
        Send the given message to this proxy's far end process.
        Parameters:
        theMessage - Message.
        Throws:
        java.io.IOException - Thrown if an I/O error occurred.
      • send

        public void send(int theTag,
                         Buf theSrc)
                  throws java.io.IOException
        Send a message with the given tag and items to this proxy's far end process.
        Parameters:
        theTag - Message tag.
        theSrc - Item source buffer.
        Throws:
        java.io.IOException - Thrown if an I/O error occurred.
      • receive

        public Status receive(Buf theDst)
                       throws java.io.IOException
        Receive a message from this proxy's far end process. A message will be received from this proxy's channel in this proxy's channel group. The message must have a tag of 0. The message items are stored in the given item destination buffer.

        The receive() method does not return until the message has been fully received.

        Parameters:
        theDst - Item destination buffer.
        Returns:
        Status object giving the outcome of the message reception.
        Throws:
        java.io.IOException - Thrown if an I/O error occurred.
      • receive

        public Status receive(java.lang.Integer theTag,
                              Buf theDst)
                       throws java.io.IOException
        Receive a message with the given tag from this proxy's far end process. A message will be received from this proxy's channel in this proxy's channel group. If theTag is null, a message will be received with any tag. The message items are stored in the given item destination buffer.

        The receive() method does not return until the message has been fully received.

        Parameters:
        theTag - Message tag, or null to receive any tag.
        theDst - Item destination buffer.
        Returns:
        Status object giving the outcome of the message reception.
        Throws:
        java.io.IOException - Thrown if an I/O error occurred.
      • close

        public void close()
        Close communication with this proxy's far end process.

DMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.