public class QosSettings
extends java.lang.Object
Constructor and Description |
---|
QosSettings()
Create a new instance with the default settings.
|
QosSettings(int deliveryMode,
int priority,
long timeToLive)
Create a new instance with the specified settings.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object other) |
int |
getDeliveryMode()
Return the delivery mode to use when sending a message.
|
int |
getPriority()
Return the priority of a message when sending.
|
long |
getTimeToLive()
Return the time-to-live of the message when sending.
|
int |
hashCode() |
void |
setDeliveryMode(int deliveryMode)
Set the delivery mode to use when sending a message.
|
void |
setPriority(int priority)
Set the priority of a message when sending.
|
void |
setTimeToLive(long timeToLive)
Set the time-to-live of the message when sending.
|
java.lang.String |
toString() |
public QosSettings()
public QosSettings(int deliveryMode, int priority, long timeToLive)
public void setDeliveryMode(int deliveryMode)
deliveryMode
- the delivery mode to useDeliveryMode.PERSISTENT
,
DeliveryMode.NON_PERSISTENT
,
Message.DEFAULT_DELIVERY_MODE
,
MessageProducer.send(javax.jms.Message, int, int, long)
public int getDeliveryMode()
public void setPriority(int priority)
public int getPriority()
public void setTimeToLive(long timeToLive)
timeToLive
- the message's lifetime (in milliseconds)Message.DEFAULT_TIME_TO_LIVE
,
MessageProducer.send(javax.jms.Message, int, int, long)
public long getTimeToLive()
public boolean equals(java.lang.Object other)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object