SourceForge.net Logo

Requirement: message.stream.null

For StreamMessage, attempting to read a null value as a Java primitive type must be treated as calling the primitive's corresponding valueOf(String) conversion method with a null value. Since char does not support a String conversion, attempting to read a null value as a char must throw NullPointerException.
NOTE: the specification is not explicit on the behaviour of invoking writeBytes() or writeString() with a null value, but an acceptable policy is to throw a NullPointerException. This is in keeping with the behaviour of DataOutputStream.

See:

  • Section 3.11.3, Conversions Provided by StreamMessage and MapMessage