Message body

The previously described portions of a message refer to the message header. The actual content of the message is contained in the message body.

The message body is an unstructured array of object references, i.e. it is an instance of java.lang.Object[] (or an array of java.lang.Object, as you like).

Figure 1: The message body

The usage of an Object array implies a great deal of flexibility, but there are certain limitations which we have to inform you about:

  You cannot send application-specific instances. If you need to send structured objects, you must transform them to one or more system class instances and transform them back (marshalling and unmarshalling) when receiving.

A structured way to perform the (un)marshalling is done by implementing the Sendable interface (see also the section about Sendables).

If the first object is a string, it is considered to be the specification.

We will describe in more detail why these restrictions turned out to be necessary and why they do not mean that the message body is inflexible.