1Z0-895 · Question #2
You are writing a client that sends a message to a JMS queue. The client includes the following code snippet:
The correct answer is D. You could add more name-value pairs to the message body of the MapMessage if they were required by. createMapMessage MapMessage createMapMessage() throws JMSException Creates a MapMessage object. A MapMessage object is used to send a self-defining set of namevalue pairs, where names are String objects and values are primitive values in the Java programming language…
Question
Options
- AThe message can be consumed by durable subscriber.
- BIn the first line, the argument to the createProducer method needs to be cast to a Destination.
- CThe message is sent using non-default deliver mode, priority, and expiration time values.
- DYou could add more name-value pairs to the message body of the MapMessage if they were required by
How the community answered
(34 responses)- A3% (1)
- B12% (4)
- C6% (2)
- D79% (27)
Explanation
createMapMessage MapMessage createMapMessage() throws JMSException Creates a MapMessage object. A MapMessage object is used to send a self-defining set of namevalue pairs, where names are String objects and values are primitive values in the Java programming language. javax.jms,Interface Session
Topics
Community Discussion
No community discussion yet for this question.