MessageProducer function ( ) { if ( completionListenerClass != null ) { return ( MessageProducer ) Proxy . newProxyInstance ( CachedMessageProducer . class . getClassLoader ( ) , new Class < ? > [ ] { MessageProducer . class , QueueSender . class , TopicPublisher . class } , new Jms2MessageProducerInvocationHandler ( ) ) ; } else { return this ; } }
build a dynamic proxy that reflectively adapts to jms 2.0 api methods , if necessary . otherwise simply return this cachedmessageproducer instance itself . concode_field_sep Boolean originalDisableMessageTimestamp concode_elem_sep long timeToLive concode_elem_sep Method setDeliveryDelayMethod concode_elem_sep Method sendWithCompletionListenerMethod concode_elem_sep Class<?> completionListenerClass concode_elem_sep int deliveryMode concode_elem_sep Method getDeliveryDelayMethod concode_elem_sep Method sendWithDestinationAndCompletionListenerMethod concode_elem_sep Long originalDeliveryDelay concode_elem_sep int priority concode_elem_sep Boolean originalDisableMessageID concode_elem_sep MessageProducer target concode_field_sep boolean getDisableMessageTimestamp concode_elem_sep Destination getDestination concode_elem_sep void setDisableMessageTimestamp concode_elem_sep void setDeliveryMode concode_elem_sep Object invoke concode_elem_sep void setDeliveryDelay concode_elem_sep long getTimeToLive concode_elem_sep Topic getTopic concode_elem_sep void setDisableMessageID concode_elem_sep long getDeliveryDelay concode_elem_sep Queue getQueue concode_elem_sep void publish concode_elem_sep void publish concode_elem_sep void publish concode_elem_sep void publish concode_elem_sep int getDeliveryMode concode_elem_sep int getPriority concode_elem_sep String toString concode_elem_sep boolean getDisableMessageID concode_elem_sep void setTimeToLive concode_elem_sep void setPriority concode_elem_sep void send concode_elem_sep void send concode_elem_sep void send concode_elem_sep void send concode_elem_sep void send concode_elem_sep void send concode_elem_sep void close