public class AmqpConnection extends AmqpAbstractResource<JmsConnectionInfo,org.apache.qpid.proton.engine.Connection> implements AmqpResourceParent
closeRequest, closeTimeoutTask
Constructor and Description |
---|
AmqpConnection(AmqpProvider provider,
JmsConnectionInfo info,
org.apache.qpid.proton.engine.Connection protonConnection) |
Modifier and Type | Method and Description |
---|---|
void |
addChildResource(AmqpResource resource)
Adds the given resource as a child of this resource so that it's
lifetime becomes managed by that of its parent.
|
void |
createSession(JmsSessionInfo sessionInfo,
AsyncResult request) |
void |
createTemporaryDestination(JmsTemporaryDestination destination,
AsyncResult request) |
AmqpJmsMessageFactory |
getAmqpMessageFactory() |
int |
getAnonymousProducerCacheSize() |
AmqpConnectionProperties |
getProperties()
Returns the connection properties for an established connection which defines the various
capabilities and configuration options of the remote connection.
|
AmqpProvider |
getProvider() |
String |
getQueuePrefix() |
URI |
getRemoteURI() |
AmqpSession |
getSession(JmsSessionId sessionId)
Retrieve the indicated Session instance from the list of active sessions.
|
AmqpTemporaryDestination |
getTemporaryDestination(JmsTemporaryDestination destination) |
String |
getTopicPrefix() |
boolean |
isAnonymousProducerCache() |
boolean |
isObjectMessageUsesAmqpTypes() |
boolean |
isPresettleConsumers() |
boolean |
isPresettleProducers() |
void |
removeChildResource(AmqpResource resource)
Removes the given resource from the registered child resources
managed by this one.
|
ScheduledFuture<?> |
schedule(Runnable task,
long delay)
Allows a connection resource to schedule a task for future execution.
|
void |
setAnonymousProducerCache(boolean anonymousProducerCache) |
void |
setAnonymousProducerCacheSize(int anonymousProducerCacheSize) |
void |
setObjectMessageUsesAmqpTypes(boolean objectMessageUsesAmqpTypes)
Configures the body type used in ObjectMessage instances that are sent from
this connection.
|
void |
setQueuePrefix(String queuePrefix) |
void |
setTopicPrefix(String topicPrefix) |
String |
toString() |
void |
unsubscribe(String subscriptionName,
AsyncResult request) |
close, closeOrDetachEndpoint, getEndpoint, getLocalState, getParent, getRemoteState, getResourceInfo, isAwaitingClose, isClosed, isOpen, processDeliveryUpdates, processFlowUpdates, processRemoteClose, processRemoteDetach, processRemoteOpen, remotelyClosed, resourceClosed
public AmqpConnection(AmqpProvider provider, JmsConnectionInfo info, org.apache.qpid.proton.engine.Connection protonConnection)
public void createSession(JmsSessionInfo sessionInfo, AsyncResult request)
public void createTemporaryDestination(JmsTemporaryDestination destination, AsyncResult request)
public AmqpTemporaryDestination getTemporaryDestination(JmsTemporaryDestination destination)
public void unsubscribe(String subscriptionName, AsyncResult request)
public void addChildResource(AmqpResource resource)
AmqpResourceParent
addChildResource
in interface AmqpResourceParent
resource
- The AmqpResource that is a child of this one.public void removeChildResource(AmqpResource resource)
AmqpResourceParent
removeChildResource
in interface AmqpResourceParent
resource
- The AmqpResource that is no longer a child of this one.public URI getRemoteURI()
public AmqpProvider getProvider()
getProvider
in interface AmqpResourceParent
public String getQueuePrefix()
public void setQueuePrefix(String queuePrefix)
public String getTopicPrefix()
public void setTopicPrefix(String topicPrefix)
public AmqpSession getSession(JmsSessionId sessionId)
sessionId
- The JmsSessionId that's associated with the target session.public boolean isPresettleConsumers()
public boolean isPresettleProducers()
public boolean isAnonymousProducerCache()
public void setAnonymousProducerCache(boolean anonymousProducerCache)
anonymousProducerCache
- enable or disables the caching or anonymous producers.public int getAnonymousProducerCacheSize()
public void setAnonymousProducerCacheSize(int anonymousProducerCacheSize)
anonymousProducerCacheSize
- the number of producers each anonymous producer instance will cache.public boolean isObjectMessageUsesAmqpTypes()
public void setObjectMessageUsesAmqpTypes(boolean objectMessageUsesAmqpTypes)
objectMessageUsesAmqpTypes
- the objectMessageUsesAmqpTypes value to set.public AmqpJmsMessageFactory getAmqpMessageFactory()
public AmqpConnectionProperties getProperties()
public ScheduledFuture<?> schedule(Runnable task, long delay)
task
- The Runnable task to be executed after the given delay.delay
- The delay in milliseconds to schedule the given task for execution.Copyright © 2013–2016 The Apache Software Foundation. All rights reserved.