JTR 5.0 API Documentation

jtr.config.jms
Class JMSSession

java.lang.Object
  extended by jtr.config.jms.JMSSession
All Implemented Interfaces:
java.io.Serializable

public class JMSSession
extends java.lang.Object
implements java.io.Serializable

This is the object oriented representation of a session element of the jtr.xml configuration file.
It logically maps itself to a javax.jms.Session.

Since:
1.1
Version:
5.0
Author:
Francesco Russo (frusso@dev.java.net)
See Also:
Serialized Form

Field Summary
static java.lang.String GENERIC_SESSION
          Mnemonic identifier for defining a generic-session
static java.lang.String QUEUE_SESSION
          Mnemonic identifier for defining a queue-session
static java.lang.String TOPIC_SESSION
          Mnemonic identifier for defining a topic-session
static java.lang.String XA_QUEUE_SESSION
          Mnemonic identifier for defining an xa-queue-session
static java.lang.String XA_SESSION
          Mnemonic identifier for defining an xa-session
static java.lang.String XA_TOPIC_SESSION
          Mnemonic identifier for defining an xa-topic-session
 
Constructor Summary
JMSSession()
          The default constructor.
 
Method Summary
 int getAckMode()
          Get the JMS ACK mode.
 java.lang.String getProperty()
          Get the name of the runner property that will hold the actual JMS session once created
 boolean getTransacted()
          Get the JMS session's transacted attribute
 java.lang.String getType()
          Get the session type.
static boolean isGenericSession(JMSSession jmsSession)
          States whether the given JMSSession is a generic session or not
static boolean isQueueSession(JMSSession jmsSession)
          States whether the given JMSSession is a queue session or not
static boolean isTopicSession(JMSSession jmsSession)
          States whether the given JMSSession is a topic session or not
static boolean isXaQueueSession(JMSSession jmsSession)
          States whether the given JMSSession is an XAQueue session or not
static boolean isXaSession(JMSSession jmsSession)
          States whether the given JMSSession is an XA session or not
static boolean isXaTopicSession(JMSSession jmsSession)
          States whether the given JMSSession is an XATopic session or not
 void setAckMode(int mode)
          Set the JMS ACK mode.
 void setProperty(java.lang.String property)
          Set the name of the runner property that will hold the actual JMS session once created
 void setTransacted(boolean t)
          Set the JMS session's transacted attribute
 void setType(java.lang.String type)
          Set the type of the session.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

QUEUE_SESSION

public static final java.lang.String QUEUE_SESSION
Mnemonic identifier for defining a queue-session

See Also:
Constant Field Values

TOPIC_SESSION

public static final java.lang.String TOPIC_SESSION
Mnemonic identifier for defining a topic-session

See Also:
Constant Field Values

GENERIC_SESSION

public static final java.lang.String GENERIC_SESSION
Mnemonic identifier for defining a generic-session

See Also:
Constant Field Values

XA_SESSION

public static final java.lang.String XA_SESSION
Mnemonic identifier for defining an xa-session

See Also:
Constant Field Values

XA_QUEUE_SESSION

public static final java.lang.String XA_QUEUE_SESSION
Mnemonic identifier for defining an xa-queue-session

See Also:
Constant Field Values

XA_TOPIC_SESSION

public static final java.lang.String XA_TOPIC_SESSION
Mnemonic identifier for defining an xa-topic-session

See Also:
Constant Field Values
Constructor Detail

JMSSession

public JMSSession()
The default constructor.

Method Detail

setType

public void setType(java.lang.String type)
Set the type of the session. Legal values are queue | topic.

Parameters:
type - The session type

getType

public java.lang.String getType()
Get the session type. Legal values are queue | topic.

Returns:
String The session type

setProperty

public void setProperty(java.lang.String property)
Set the name of the runner property that will hold the actual JMS session once created

Parameters:
property - The property name

getProperty

public java.lang.String getProperty()
Get the name of the runner property that will hold the actual JMS session once created

Returns:
String The property name

setTransacted

public void setTransacted(boolean t)
Set the JMS session's transacted attribute

Parameters:
t - Is the session transacted?

getTransacted

public boolean getTransacted()
Get the JMS session's transacted attribute

Returns:
boolean Is the session transacted?

setAckMode

public void setAckMode(int mode)
Set the JMS ACK mode.

Parameters:
mode - The ACK mode

getAckMode

public int getAckMode()
Get the JMS ACK mode.

Returns:
int The ACK mode

isQueueSession

public static boolean isQueueSession(JMSSession jmsSession)
States whether the given JMSSession is a queue session or not

Parameters:
jmsSession - JMSSession
Returns:
boolean

isTopicSession

public static boolean isTopicSession(JMSSession jmsSession)
States whether the given JMSSession is a topic session or not

Parameters:
jmsSession - JMSSession
Returns:
boolean

isGenericSession

public static boolean isGenericSession(JMSSession jmsSession)
States whether the given JMSSession is a generic session or not

Parameters:
jmsSession - JMSSession
Returns:
boolean

isXaSession

public static boolean isXaSession(JMSSession jmsSession)
States whether the given JMSSession is an XA session or not

Parameters:
jmsSession - JMSSession
Returns:
boolean

isXaQueueSession

public static boolean isXaQueueSession(JMSSession jmsSession)
States whether the given JMSSession is an XAQueue session or not

Parameters:
jmsSession - JMSSession
Returns:
boolean

isXaTopicSession

public static boolean isXaTopicSession(JMSSession jmsSession)
States whether the given JMSSession is an XATopic session or not

Parameters:
jmsSession - JMSSession
Returns:
boolean

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object
See Also:
Object.toString()

The JTR Project is licensed under GPL version 2