Reads an object from the stream message.
This method can be used to return, in objectified format, an object in the Java programming language ("Java object") that has been written to the stream with the equivalent writeObject method call, or its equivalent primitive writetype method.
Note that byte values are returned as byte[], not Byte[].
An attempt to call readObject to read a byte field value into a new byte[] object before the full value of the byte field has been read will throw a MessageFormatException.
@return a Java object from the stream message, in objectified format (forexample, if the object was written as an int, an Integer is returned)
@throws JMSException if the JMS provider fails to read the message due tosome internal error.
@throws MessageEOFException if unexpected end of message stream has beenreached.
@throws MessageFormatException if this type conversion is invalid.
@throws MessageNotReadableException if the message is in write-only mode.
@see #readBytes(byte[] value)