jsr343-experts@jms-spec.java.net

[jsr343-experts] Re: [jms-spec users] Re: (JMS_SPEC-101) New method Message.getPayload(Class<T> c)

From: Rob Davies <rajdavies_at_gmail.com>
Date: Wed, 24 Oct 2012 12:14:47 +0100

On 24 Oct 2012, at 12:04, Nigel Deakin <nigel.deakin_at_oracle.com> wrote:

> The word "payload" already implies the idea that it is a wrapped object, so I think unwrapPayload would be a tautology.
>
> However, having just checked the spec, I see that the word "payload" is my own invention. Although the word "payload" appears 45 times in the 2.0 spec, it doesn't appear at all in the 1.1 spec. The term used in 1.1 is "body" (e.g. in methods such as clearBody()). This makes me wonder whether I should replace all references to "payload" with "body". So this new method on Message would become "getBody" and the receivePayload() methods on JMSConsumer would become receiveBody(). Hmm.
>
> Does anyone have any comments on that? Is a mix of "payload" and "body" OK, or should I make everything "body" consistently?
>

Although payload makes more sense to me than 'body' - for the sake of consistency - it would be better to make everything 'body' imho

thanks,

Rob