|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface Body
The message body holds arbitrary information which represents the payload as far as clients and services are concerned. A body may contain: (i) a byte array for arbitrary data. How that array is interpreted by the service is implementation specific and outside the scope of the ESB to enforce. (ii) a list of Objects of arbitrary types. How these objects are serialized to/from the message body when it is transmitted is up to the specific Object type. The plan is to add support for various TYPES of Object and the message implementation will use external adapters to externalize/internalize the Objects. Currently we only support Serializable objects.
| Method Summary | |
|---|---|
void |
add(java.lang.String name,
java.lang.Object value)
Add the specified Object to the body. |
java.lang.Object |
get(java.lang.String name)
Get the specified Object, or null if not present. |
byte[] |
getContents()
|
void |
merge(Body b)
Merge two bodies. |
java.lang.Object |
remove(java.lang.String name)
Remove the specified Object and return it, or null if not present. |
void |
replace(Body b)
Replace this body instance with the one given. |
void |
setContents(byte[] content)
Set the byte content of the body. |
| Method Detail |
|---|
void add(java.lang.String name,
java.lang.Object value)
name - the name of the object. MUST be unique within this body.value - the Object to add.java.lang.Object get(java.lang.String name)
null if not present.
name - the name of the Object to retrieve.
java.lang.Object remove(java.lang.String name)
null if not present.
name - the name of the Object to remove.
void setContents(byte[] content)
content - the message bytesbyte[] getContents()
void replace(Body b)
b - the body to be replaced with.void merge(Body b)
b - the body to be merged with.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||