oracle.panama.messaging.common
Class Header
java.lang.Object
|
+--oracle.panama.messaging.common.Header
- All Implemented Interfaces:
- java.io.Externalizable, java.io.Serializable
- public class Header
- extends java.lang.Object
- implements java.io.Externalizable
The class maintains the name/value pair to represent a header of the MessagePart.
A few commonly used headers are defined as constants in MessagePart class. The
application specific header can be added as long as both sender and recipient
agree upon the meaning associated with the header name.
- See Also:
- Serialized Form
Header()
|
Header(java.lang.String name,
java.lang.String value)
Constructor. |
Type | Method |
java.lang.String |
getName()
Returns the name of this header. |
java.lang.String |
getValue()
Returns the value of this header. |
void |
readExternal(java.io.ObjectInput oi)
Read a message instance from a stream. |
void |
setName(java.lang.String name,
java.lang.String value)
Set the name and value of the header. |
void |
writeExternal(java.io.ObjectOutput oo)
Write a message instance to a stream. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Header
public Header()
Header
public Header(java.lang.String name,
java.lang.String value)
- Constructor.
getName
public java.lang.String getName()
- Returns the name of this header.
- Returns:
- the name of the header.
getValue
public java.lang.String getValue()
- Returns the value of this header.
- Returns:
- the value of this header.
setName
public void setName(java.lang.String name,
java.lang.String value)
- Set the name and value of the header.
- Parameters:
name
- name of the header.value
- value of the header.
readExternal
public void readExternal(java.io.ObjectInput oi)
throws java.io.IOException,
java.lang.ClassNotFoundException
- Read a message instance from a stream.
- Specified by:
readExternal
in interface java.io.Externalizable
- Parameters:
oi
- the stream to read from.
writeExternal
public void writeExternal(java.io.ObjectOutput oo)
throws java.io.IOException
- Write a message instance to a stream.
- Specified by:
writeExternal
in interface java.io.Externalizable
- Parameters:
oo
- the stream to write to.