Class Recipient


  • public class Recipient
    extends Recip
    Provides a class that abstracts the recipient of a message.
    This is used both when composing message to send, and also for processing received messages.
    • Constructor Summary

      Constructors 
      Constructor Description
      Recipient()
      Create an empty recipient.
      Recipient​(int attr, java.lang.String value)
      Create a recipient, using the given attribute and value.
    • Constructor Detail

      • Recipient

        public Recipient()
        Create an empty recipient. The values can be set later on with the set*() methods.
      • Recipient

        public Recipient​(int attr,
                         java.lang.String value)
        Create a recipient, using the given attribute and value.

        For example, to create a Recipient with an O/R address, use the value X400_att.X400_S_OR_ADDRESS for attr, and the String encoded O/R address for the value.

        Another attr value supported is X400_att.X400_S_DIRECTORY_NAME which creates a Recipient using the DN.

        If attr is neither of these values, it will be assumed that the value passed is an string encoded O/R Name, which has the syntax:
        DN $ OR

        That is, a DN followed by the string " $ " and the O/R address.

        Parameters:
        attr - X400_att.X400_S_OR_ADDRESS or X400_att.X400_S_DIRECTORY_NAME
        value -
    • Method Detail

      • toString

        public java.lang.String toString()
        Overwrite the method, so that the O/R address becomes the normal way to represent it
        Overrides:
        toString in class java.lang.Object
      • getORAddress

        public java.lang.String getORAddress()
        Returns:
        the O/R address of the recipient
      • setORAddress

        public void setORAddress​(java.lang.String or)
        Sets the O/R address of the recipient
        Parameters:
        or - - The String encoded O/R address
      • getDN

        public java.lang.String getDN()
        Returns:
        the DN of the recipient
      • setDN

        public void setDN​(java.lang.String d)
        Sets the DN of the recipient
        Parameters:
        d -
      • getNotificationRequest

        public int getNotificationRequest()
        Returns:
        the Notification Request for this recipient
      • setNotificationRequest

        public void setNotificationRequest​(int r)
        Sets the notification request for this recipient
        Parameters:
        r -
      • getReplyRequest

        public int getReplyRequest()
        Returns:
        the Reply Request for this recipient
      • setReplyRequest

        public void setReplyRequest​(int reply_request)
        Sets the Reply Request for this recipient
      • getFreeFormName

        public java.lang.String getFreeFormName()
        Returns:
        the Free Form name for this recipient
        For example "John Smith"
      • setFreeFormName

        public void setFreeFormName​(java.lang.String f)
        Sets the Free Form Name for this recipient.
        For example "John Smith"
        Parameters:
        f -
      • getPrecedence

        public int getPrecedence()
        Returns:
        the Precedence value for this recipient
      • setPrecedence

        public void setPrecedence​(int r)
        Sets the Precedence value for this recipient
        Parameters:
        r -