Package org.apache.activemq.artemis.jms.client

## Class ActiveMQJMSProducer

- java.lang.Object
- - org.apache.activemq.artemis.jms.client.ActiveMQJMSProducer

- All Implemented Interfaces:
    `javax.jms.JMSProducer`

      public final class ActiveMQJMSProducer
      extends java.lang.Object
      implements javax.jms.JMSProducer

  NOTE: this class forwards `setDisableMessageID(boolean)` and `setDisableMessageTimestamp(boolean)` calls their equivalent at the `MessageProducer`. IF the user is using the producer in async mode, this may lead to races. We allow/tolerate this because these are just optional optimizations.

- - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `javax.jms.JMSProducer` | `clearProperties()` |
    `javax.jms.CompletionListener` | `getAsync()` |
    `boolean` | `getBooleanProperty​(java.lang.String name)` |
    `byte` | `getByteProperty​(java.lang.String name)` |
    `long` | `getDeliveryDelay()` |
    `int` | `getDeliveryMode()` |
    `boolean` | `getDisableMessageID()` |
    `boolean` | `getDisableMessageTimestamp()` |
    `double` | `getDoubleProperty​(java.lang.String name)` |
    `float` | `getFloatProperty​(java.lang.String name)` |
    `int` | `getIntProperty​(java.lang.String name)` |
    `java.lang.String` | `getJMSCorrelationID()` |
    `byte[]` | `getJMSCorrelationIDAsBytes()` |
    `javax.jms.Destination` | `getJMSReplyTo()` |
    `java.lang.String` | `getJMSType()` |
    `long` | `getLongProperty​(java.lang.String name)` |
    `java.lang.Object` | `getObjectProperty​(java.lang.String name)` |
    `int` | `getPriority()` |
    `java.util.Set<java.lang.String>` | `getPropertyNames()` |
    `short` | `getShortProperty​(java.lang.String name)` |
    `java.lang.String` | `getStringProperty​(java.lang.String name)` |
    `long` | `getTimeToLive()` |
    `boolean` | `propertyExists​(java.lang.String name)` |
    `javax.jms.JMSProducer` | `send​(javax.jms.Destination destination, byte[] body)` |
    `javax.jms.JMSProducer` | `send​(javax.jms.Destination destination, java.io.Serializable body)` |
    `javax.jms.JMSProducer` | `send​(javax.jms.Destination destination, java.lang.String body)` |
    `javax.jms.JMSProducer` | `send​(javax.jms.Destination destination, java.util.Map<java.lang.String,​java.lang.Object> body)` |
    `javax.jms.JMSProducer` | `send​(javax.jms.Destination destination, javax.jms.Message message)` |
    `javax.jms.JMSProducer` | `setAsync​(javax.jms.CompletionListener completionListener)` |
    `javax.jms.JMSProducer` | `setDeliveryDelay​(long deliveryDelay)` |
    `javax.jms.JMSProducer` | `setDeliveryMode​(int deliveryMode)` |
    `javax.jms.JMSProducer` | `setDisableMessageID​(boolean value)` |
    `javax.jms.JMSProducer` | `setDisableMessageTimestamp​(boolean value)` |
    `javax.jms.JMSProducer` | `setJMSCorrelationID​(java.lang.String correlationID)` |
    `javax.jms.JMSProducer` | `setJMSCorrelationIDAsBytes​(byte[] correlationID)` |
    `javax.jms.JMSProducer` | `setJMSReplyTo​(javax.jms.Destination replyTo)` |
    `javax.jms.JMSProducer` | `setJMSType​(java.lang.String type)` |
    `javax.jms.JMSProducer` | `setPriority​(int priority)` |
    `javax.jms.JMSProducer` | `setProperty​(java.lang.String name, boolean value)` |
    `javax.jms.JMSProducer` | `setProperty​(java.lang.String name, byte value)` |
    `javax.jms.JMSProducer` | `setProperty​(java.lang.String name, double value)` |
    `javax.jms.JMSProducer` | `setProperty​(java.lang.String name, float value)` |
    `javax.jms.JMSProducer` | `setProperty​(java.lang.String name, int value)` |
    `javax.jms.JMSProducer` | `setProperty​(java.lang.String name, long value)` |
    `javax.jms.JMSProducer` | `setProperty​(java.lang.String name, short value)` |
    `javax.jms.JMSProducer` | `setProperty​(java.lang.String name, java.lang.Object value)` |
    `javax.jms.JMSProducer` | `setProperty​(java.lang.String name, java.lang.String value)` |
    `javax.jms.JMSProducer` | `setTimeToLive​(long timeToLive)` |

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Method Detail

    - #### send

          public javax.jms.JMSProducer send​(javax.jms.Destination destination,
                                            javax.jms.Message message)

      Specified by:
        `send` in interface `javax.jms.JMSProducer`

    - #### send

          public javax.jms.JMSProducer send​(javax.jms.Destination destination,
                                            java.lang.String body)

      Specified by:
        `send` in interface `javax.jms.JMSProducer`

    - #### send

          public javax.jms.JMSProducer send​(javax.jms.Destination destination,
                                            java.util.Map<java.lang.String,​java.lang.Object> body)

      Specified by:
        `send` in interface `javax.jms.JMSProducer`

    - #### send

          public javax.jms.JMSProducer send​(javax.jms.Destination destination,
                                            byte[] body)

      Specified by:
        `send` in interface `javax.jms.JMSProducer`

    - #### send

          public javax.jms.JMSProducer send​(javax.jms.Destination destination,
                                            java.io.Serializable body)

      Specified by:
        `send` in interface `javax.jms.JMSProducer`

    - #### setDisableMessageID

          public javax.jms.JMSProducer setDisableMessageID​(boolean value)

      Specified by:
        `setDisableMessageID` in interface `javax.jms.JMSProducer`

    - #### getDisableMessageID

          public boolean getDisableMessageID()

      Specified by:
        `getDisableMessageID` in interface `javax.jms.JMSProducer`

    - #### setDisableMessageTimestamp

          public javax.jms.JMSProducer setDisableMessageTimestamp​(boolean value)

      Specified by:
        `setDisableMessageTimestamp` in interface `javax.jms.JMSProducer`

    - #### getDisableMessageTimestamp

          public boolean getDisableMessageTimestamp()

      Specified by:
        `getDisableMessageTimestamp` in interface `javax.jms.JMSProducer`

    - #### setDeliveryMode

          public javax.jms.JMSProducer setDeliveryMode​(int deliveryMode)

      Specified by:
        `setDeliveryMode` in interface `javax.jms.JMSProducer`

    - #### getDeliveryMode

          public int getDeliveryMode()

      Specified by:
        `getDeliveryMode` in interface `javax.jms.JMSProducer`

    - #### setPriority

          public javax.jms.JMSProducer setPriority​(int priority)

      Specified by:
        `setPriority` in interface `javax.jms.JMSProducer`

    - #### getPriority

          public int getPriority()

      Specified by:
        `getPriority` in interface `javax.jms.JMSProducer`

    - #### setTimeToLive

          public javax.jms.JMSProducer setTimeToLive​(long timeToLive)

      Specified by:
        `setTimeToLive` in interface `javax.jms.JMSProducer`

    - #### getTimeToLive

          public long getTimeToLive()

      Specified by:
        `getTimeToLive` in interface `javax.jms.JMSProducer`

    - #### setDeliveryDelay

          public javax.jms.JMSProducer setDeliveryDelay​(long deliveryDelay)

      Specified by:
        `setDeliveryDelay` in interface `javax.jms.JMSProducer`

    - #### getDeliveryDelay

          public long getDeliveryDelay()

      Specified by:
        `getDeliveryDelay` in interface `javax.jms.JMSProducer`

    - #### setAsync

          public javax.jms.JMSProducer setAsync​(javax.jms.CompletionListener completionListener)

      Specified by:
        `setAsync` in interface `javax.jms.JMSProducer`

    - #### getAsync

          public javax.jms.CompletionListener getAsync()

      Specified by:
        `getAsync` in interface `javax.jms.JMSProducer`

    - #### setProperty

          public javax.jms.JMSProducer setProperty​(java.lang.String name,
                                                   boolean value)

      Specified by:
        `setProperty` in interface `javax.jms.JMSProducer`

    - #### setProperty

          public javax.jms.JMSProducer setProperty​(java.lang.String name,
                                                   byte value)

      Specified by:
        `setProperty` in interface `javax.jms.JMSProducer`

    - #### setProperty

          public javax.jms.JMSProducer setProperty​(java.lang.String name,
                                                   short value)

      Specified by:
        `setProperty` in interface `javax.jms.JMSProducer`

    - #### setProperty

          public javax.jms.JMSProducer setProperty​(java.lang.String name,
                                                   int value)

      Specified by:
        `setProperty` in interface `javax.jms.JMSProducer`

    - #### setProperty

          public javax.jms.JMSProducer setProperty​(java.lang.String name,
                                                   long value)

      Specified by:
        `setProperty` in interface `javax.jms.JMSProducer`

    - #### setProperty

          public javax.jms.JMSProducer setProperty​(java.lang.String name,
                                                   float value)

      Specified by:
        `setProperty` in interface `javax.jms.JMSProducer`

    - #### setProperty

          public javax.jms.JMSProducer setProperty​(java.lang.String name,
                                                   double value)

      Specified by:
        `setProperty` in interface `javax.jms.JMSProducer`

    - #### setProperty

          public javax.jms.JMSProducer setProperty​(java.lang.String name,
                                                   java.lang.String value)

      Specified by:
        `setProperty` in interface `javax.jms.JMSProducer`

    - #### setProperty

          public javax.jms.JMSProducer setProperty​(java.lang.String name,
                                                   java.lang.Object value)

      Specified by:
        `setProperty` in interface `javax.jms.JMSProducer`

    - #### clearProperties

          public javax.jms.JMSProducer clearProperties()

      Specified by:
        `clearProperties` in interface `javax.jms.JMSProducer`

    - #### propertyExists

          public boolean propertyExists​(java.lang.String name)

      Specified by:
        `propertyExists` in interface `javax.jms.JMSProducer`

    - #### getBooleanProperty

          public boolean getBooleanProperty​(java.lang.String name)

      Specified by:
        `getBooleanProperty` in interface `javax.jms.JMSProducer`

    - #### getByteProperty

          public byte getByteProperty​(java.lang.String name)

      Specified by:
        `getByteProperty` in interface `javax.jms.JMSProducer`

    - #### getShortProperty

          public short getShortProperty​(java.lang.String name)

      Specified by:
        `getShortProperty` in interface `javax.jms.JMSProducer`

    - #### getIntProperty

          public int getIntProperty​(java.lang.String name)

      Specified by:
        `getIntProperty` in interface `javax.jms.JMSProducer`

    - #### getLongProperty

          public long getLongProperty​(java.lang.String name)

      Specified by:
        `getLongProperty` in interface `javax.jms.JMSProducer`

    - #### getFloatProperty

          public float getFloatProperty​(java.lang.String name)

      Specified by:
        `getFloatProperty` in interface `javax.jms.JMSProducer`

    - #### getDoubleProperty

          public double getDoubleProperty​(java.lang.String name)

      Specified by:
        `getDoubleProperty` in interface `javax.jms.JMSProducer`

    - #### getStringProperty

          public java.lang.String getStringProperty​(java.lang.String name)

      Specified by:
        `getStringProperty` in interface `javax.jms.JMSProducer`

    - #### getObjectProperty

          public java.lang.Object getObjectProperty​(java.lang.String name)

      Specified by:
        `getObjectProperty` in interface `javax.jms.JMSProducer`

    - #### getPropertyNames

          public java.util.Set<java.lang.String> getPropertyNames()

      Specified by:
        `getPropertyNames` in interface `javax.jms.JMSProducer`

    - #### setJMSCorrelationIDAsBytes

          public javax.jms.JMSProducer setJMSCorrelationIDAsBytes​(byte[] correlationID)

      Specified by:
        `setJMSCorrelationIDAsBytes` in interface `javax.jms.JMSProducer`

    - #### getJMSCorrelationIDAsBytes

          public byte[] getJMSCorrelationIDAsBytes()

      Specified by:
        `getJMSCorrelationIDAsBytes` in interface `javax.jms.JMSProducer`

    - #### setJMSCorrelationID

          public javax.jms.JMSProducer setJMSCorrelationID​(java.lang.String correlationID)

      Specified by:
        `setJMSCorrelationID` in interface `javax.jms.JMSProducer`

    - #### getJMSCorrelationID

          public java.lang.String getJMSCorrelationID()

      Specified by:
        `getJMSCorrelationID` in interface `javax.jms.JMSProducer`

    - #### setJMSType

          public javax.jms.JMSProducer setJMSType​(java.lang.String type)

      Specified by:
        `setJMSType` in interface `javax.jms.JMSProducer`

    - #### getJMSType

          public java.lang.String getJMSType()

      Specified by:
        `getJMSType` in interface `javax.jms.JMSProducer`

    - #### setJMSReplyTo

          public javax.jms.JMSProducer setJMSReplyTo​(javax.jms.Destination replyTo)

      Specified by:
        `setJMSReplyTo` in interface `javax.jms.JMSProducer`

    - #### getJMSReplyTo

          public javax.jms.Destination getJMSReplyTo()

      Specified by:
        `getJMSReplyTo` in interface `javax.jms.JMSProducer`