Package com.isode.x400.highlevel
Class Recipient
- java.lang.Object
-
- com.isode.x400api.Recip
-
- com.isode.x400.highlevel.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.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getDN()
java.lang.String
getFreeFormName()
int
getNotificationRequest()
java.lang.String
getORAddress()
int
getPrecedence()
int
getReplyRequest()
void
setDN(java.lang.String d)
Sets the DN of the recipientvoid
setFreeFormName(java.lang.String f)
Sets the Free Form Name for this recipient.void
setNotificationRequest(int r)
Sets the notification request for this recipientvoid
setORAddress(java.lang.String or)
Sets the O/R address of the recipientvoid
setPrecedence(int r)
Sets the Precedence value for this recipientvoid
setReplyRequest(int reply_request)
Sets the Reply Request for this recipientjava.lang.String
toString()
Overwrite the method, so that the O/R address becomes the normal way to represent it-
Methods inherited from class com.isode.x400api.Recip
GetIntValue, GetType
-
-
-
-
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 $ ORThat 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_NAMEvalue
-
-
-
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 classjava.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
-
-
-