com.bea.b2b.protocol.rosettanet.messaging
Class RNMessage

java.lang.Object
  |
  +--com.bea.b2b.protocol.messaging.MessageBase
        |
        +--com.bea.b2b.protocol.rosettanet.messaging.RNMessage

public class RNMessage
extends MessageBase
implements Message

The RNMessage class represents a RosettaNet message. It contains additional information that is associated with RosettaNet processing.

Author:
Copyright © 2000 BEA Systems, Inc. All Rights Reserved.
See Also:
Serialized Form

Method Summary
 void addRecipient(java.lang.String rec)
          Adds the specified recipient to the recipients list for this message.
 PreamblePart getPreamble()
          Gets the RosettaNet Preamble portion of this message.
 ServiceContentPart getServiceContent()
          Gets the RosettaNet Service Content portion of this message.
 ServiceHeaderPart getServiceHeader()
          Gets the RosettaNet Service Header portion of this message.
 Attachment getSignature()
          Gets the Digital Signature portion of this message.
 void removeAllRecipients()
          Removes all recipients from the recipients list for this message.
 boolean removeRecipient(java.lang.String rec)
          Removes the specified recipient from recipients list for this message.
 MessageToken send()
          Sends this message to the recipient trading partner(s).
 void setServiceContent(ServiceContentPart content)
          Sets the RosettaNet Service Content portion of this message.
 void setSignature(Attachment signature)
          Sets the Digital Signature portion of this message.
 
Methods inherited from class com.bea.b2b.protocol.messaging.MessageBase
addPayloadPart, addPayloadParts, getConversationId, getConversationType, getCreationTime, getMessageId, getPayloadParts, getRecipients, isBusinessMessage, removeAllPayloadParts, setToRole
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getPreamble

public PreamblePart getPreamble()
Gets the RosettaNet Preamble portion of this message.

Returns:
PreamblePart - Preamble portion.

getServiceHeader

public ServiceHeaderPart getServiceHeader()
Gets the RosettaNet Service Header portion of this message.

Returns:
ServiceHeaderPart - Service Header portion.

getServiceContent

public ServiceContentPart getServiceContent()
Gets the RosettaNet Service Content portion of this message.

Returns:
ServiceContentPart - Service Content portion.

setServiceContent

public void setServiceContent(ServiceContentPart content)
Sets the RosettaNet Service Content portion of this message.

Parameters:
ServiceContentPart - - Service Content portion.

getSignature

public Attachment getSignature()
Gets the Digital Signature portion of this message.

Returns:
Attachment - Digital Signature portion.

setSignature

public void setSignature(Attachment signature)
Sets the Digital Signature portion of this message.

Parameters:
Attachment - - Digital Signature portion.

send

public MessageToken send()
                  throws MessageDeliveryException
Sends this message to the recipient trading partner(s).

This method is not available on the c-hub and will throw the MessageDeliveryException if attempted.

Specified by:
send in interface Message

Returns:
MessageToken - Message token.
Throws:
MessageDeliveryException - If this method was called on the c-hub.

addRecipient

public void addRecipient(java.lang.String rec)
                  throws ModificationException
Adds the specified recipient to the recipients list for this message. Duplicate recipients are removed automatically. All recipients are validated later when the message is about to be queued for delivery. Usage of this method is restricted to the c-hub only.
Specified by:
addRecipient in interface Message

Throws:
ModificationException - If an error occurred during message modification.
Overrides:
addRecipient in class MessageBase

removeAllRecipients

public void removeAllRecipients()
                         throws ModificationException
Removes all recipients from the recipients list for this message. Usage of this method is restricted to the c-hub only.
Specified by:
removeAllRecipients in interface Message

Throws:
ModificationException - If an error occurred during message modification.
Overrides:
removeAllRecipients in class MessageBase

removeRecipient

public boolean removeRecipient(java.lang.String rec)
                        throws ModificationException
Removes the specified recipient from recipients list for this message. Usage of this method is restricted to the c-hub only.
Specified by:
removeRecipient in interface Message

Returns:
boolean - true if the specified recipient existed and was removed, or false if the specified recipient did not exist in the recipient list.
Overrides:
removeRecipient in class MessageBase