org.jboss.resource.adapter.jms
Class JmsManagedConnectionFactory

java.lang.Object
  extended byorg.jboss.resource.adapter.jms.JmsManagedConnectionFactory
All Implemented Interfaces:
ManagedConnectionFactory (src) , java.io.Serializable

public class JmsManagedConnectionFactory
extends java.lang.Object
implements ManagedConnectionFactory (src)

??? Created: Sat Mar 31 03:08:35 2001

See Also:
Serialized Form

Constructor Summary
JmsManagedConnectionFactory()
           
 
Method Summary
 java.lang.Object createConnectionFactory()
          Create a "non managed" connection factory.
 java.lang.Object createConnectionFactory(ConnectionManager (src)  cxManager)
          Create a ConnectionFactory with appserver hook
 ManagedConnection (src) createManagedConnection(javax.security.auth.Subject subject, ConnectionRequestInfo (src)  info)
          Create a new connection to manage in pool
 boolean equals(java.lang.Object obj)
          Checks for equality ower the configured properties.
 java.lang.String getClientID()
          Get client id, may be null.
 JMSProviderAdapter (src) getJmsProviderAdapter()
           
 java.lang.String getJmsProviderAdapterJNDI()
           
 java.io.PrintWriter getLogWriter()
          Gets the logwriter for this instance.
 ConnectionMetaData (src) getMetaData()
           
 java.lang.String getPassword()
          Get password, may be null.
protected  JmsMCFProperties (src) getProperties()
           
 java.lang.String getSessionDefaultType()
           
 java.lang.String getUserName()
          Get userName, may be null.
 int hashCode()
          Generates a hashCode for this object
 boolean isStrict()
           
 ManagedConnection (src) matchManagedConnections(java.util.Set connectionSet, javax.security.auth.Subject subject, ConnectionRequestInfo (src)  info)
          Match a set of connections from the pool
 void setClientID(java.lang.String clientID)
          Set client id, null by default.
 void setJmsProviderAdapter(JMSProviderAdapter (src)  adapter)
          For local access
 void setJmsProviderAdapterJNDI(java.lang.String jndi)
           
 void setLogWriter(java.io.PrintWriter out)
          Sets the logwriter for this instance.
 void setPassword(java.lang.String password)
          Set password, null by default.
 void setSessionDefaultType(java.lang.String type)
          Set the default session typ
 void setStrict(boolean strict)
           
 void setStrict(java.lang.Boolean strict)
           
 void setUserName(java.lang.String userName)
          Set userName, null by default.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JmsManagedConnectionFactory

public JmsManagedConnectionFactory()
Method Detail

createConnectionFactory

public java.lang.Object createConnectionFactory()
                                         throws ResourceException (src) 
Create a "non managed" connection factory. No appserver involved

Specified by:
createConnectionFactory in interface ManagedConnectionFactory (src)
Returns:
the connection factory
Throws:
ResourceException (src) - for a generic error

createConnectionFactory

public java.lang.Object createConnectionFactory(ConnectionManager (src)  cxManager)
                                         throws ResourceException (src) 
Create a ConnectionFactory with appserver hook

Specified by:
createConnectionFactory in interface ManagedConnectionFactory (src)
Parameters:
cxManager - the connection manager
Returns:
the connection factory
Throws:
ResourceException (src) - for a generic error

createManagedConnection

public ManagedConnection (src)  createManagedConnection(javax.security.auth.Subject subject,
                                                 ConnectionRequestInfo (src)  info)
                                          throws ResourceException (src) 
Create a new connection to manage in pool

Specified by:
createManagedConnection in interface ManagedConnectionFactory (src)
Parameters:
subject - the subject
info - the connection request info
Returns:
the managed connection
Throws:
ResourceException (src) - for a generic error

matchManagedConnections

public ManagedConnection (src)  matchManagedConnections(java.util.Set connectionSet,
                                                 javax.security.auth.Subject subject,
                                                 ConnectionRequestInfo (src)  info)
                                          throws ResourceException (src) 
Match a set of connections from the pool

Specified by:
matchManagedConnections in interface ManagedConnectionFactory (src)
Parameters:
connectionSet - the connection set
subject - the subject
info - the connection request info
Returns:
the managed connection
Throws:
ResourceException (src) - for a generic error

setLogWriter

public void setLogWriter(java.io.PrintWriter out)
                  throws ResourceException (src) 
Description copied from interface: ManagedConnectionFactory (src)
Sets the logwriter for this instance.

Specified by:
setLogWriter in interface ManagedConnectionFactory (src)
Parameters:
out - the log writer
Throws:
ResourceException (src) - for a generic error

getLogWriter

public java.io.PrintWriter getLogWriter()
                                 throws ResourceException (src) 
Description copied from interface: ManagedConnectionFactory (src)
Gets the logwriter for this instance.

Specified by:
getLogWriter in interface ManagedConnectionFactory (src)
Returns:
the log writer
Throws:
ResourceException (src) - for a generic error

equals

public boolean equals(java.lang.Object obj)
Checks for equality ower the configured properties.

Specified by:
equals in interface ManagedConnectionFactory (src)

hashCode

public int hashCode()
Description copied from interface: ManagedConnectionFactory (src)
Generates a hashCode for this object

Specified by:
hashCode in interface ManagedConnectionFactory (src)

setJmsProviderAdapterJNDI

public void setJmsProviderAdapterJNDI(java.lang.String jndi)

getJmsProviderAdapterJNDI

public java.lang.String getJmsProviderAdapterJNDI()

setUserName

public void setUserName(java.lang.String userName)
Set userName, null by default.


getUserName

public java.lang.String getUserName()
Get userName, may be null.


setPassword

public void setPassword(java.lang.String password)
Set password, null by default.


getPassword

public java.lang.String getPassword()
Get password, may be null.


getClientID

public java.lang.String getClientID()
Get client id, may be null.


setClientID

public void setClientID(java.lang.String clientID)
Set client id, null by default.


isStrict

public boolean isStrict()

setStrict

public void setStrict(boolean strict)

setStrict

public void setStrict(java.lang.Boolean strict)

setSessionDefaultType

public void setSessionDefaultType(java.lang.String type)
                           throws ResourceException (src) 
Set the default session typ

Parameters:
type - either javax.jms.Topic or javax.jms.Queue
Throws:
ResourceException (src) - if type was not a valid type.

getSessionDefaultType

public java.lang.String getSessionDefaultType()

setJmsProviderAdapter

public void setJmsProviderAdapter(JMSProviderAdapter (src)  adapter)
For local access


getJmsProviderAdapter

public JMSProviderAdapter (src)  getJmsProviderAdapter()

getMetaData

public ConnectionMetaData (src)  getMetaData()

getProperties

protected JmsMCFProperties (src)  getProperties()