站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > JBoss 4.0.1 sp1 varia API Documentation 英文版文档

DataSourceInterceptor (Various API) - JBoss 4.0.1 sp1 varia API Documentation 英文版文档


org.jboss.varia.stats
Class DataSourceInterceptor

java.lang.Object
  extended byorg.jboss.mx.util.JBossNotificationBroadcasterSupport
      extended byorg.jboss.system.ServiceMBeanSupport
          extended byorg.jboss.varia.stats.DataSourceInterceptor
All Implemented Interfaces:
DataSource, DataSourceInterceptorMBean, javax.management.MBeanRegistration, javax.management.NotificationBroadcaster, javax.management.NotificationEmitter, org.jboss.system.Service, org.jboss.system.ServiceMBean

public class DataSourceInterceptor
extends org.jboss.system.ServiceMBeanSupport
implements DataSource, DataSourceInterceptorMBean

Version:
$Revision: 1.6 $
Author:
Alexey Loubyansky

Nested Class Summary
 class DataSourceInterceptor.ConnectionInterceptor
           
 class DataSourceInterceptor.PreparedStatementInterceptor
           
 class DataSourceInterceptor.StatementInterceptor
           
 
Field Summary
 
Fields inherited from class org.jboss.system.ServiceMBeanSupport
log, server, SERVICE_CONTROLLER_SIG, serviceName
 
Fields inherited from interface org.jboss.varia.stats.DataSourceInterceptorMBean
OBJECT_NAME
 
Fields inherited from interface org.jboss.system.ServiceMBean
CREATE_EVENT, CREATED, DESTROY_EVENT, DESTROYED, FAILED, REGISTERED, START_EVENT, STARTED, STARTING, states, STOP_EVENT, STOPPED, STOPPING, UNREGISTERED
 
Constructor Summary
DataSourceInterceptor()
           
 
Method Summary
 String getBindName()
           
 Connection getConnection()
           
 Connection getConnection(String username, String password)
           
 int getLoginTimeout()
           
 PrintWriter getLogWriter()
           
 javax.management.ObjectName getStatsCollector()
           
 String getTargetName()
           
 void setBindName(String bindName)
           
 void setLoginTimeout(int seconds)
           
 void setLogWriter(PrintWriter out)
           
 void setStatsCollector(javax.management.ObjectName statsCollector)
           
 void setTargetName(String targetName)
           
 void startService()
           
 void stopService()
           
 
Methods inherited from class org.jboss.system.ServiceMBeanSupport
create, createService, destroy, destroyService, getLog, getName, getNextNotificationSequenceNumber, getObjectName, getServer, getServiceName, getState, getStateString, jbossInternalCreate, jbossInternalDescription, jbossInternalDestroy, jbossInternalLifecycle, jbossInternalStart, jbossInternalStop, postDeregister, postRegister, preDeregister, preRegister, start, stop
 
Methods inherited from class org.jboss.mx.util.JBossNotificationBroadcasterSupport
addNotificationListener, getNotificationInfo, handleNotification, removeNotificationListener, removeNotificationListener, sendNotification
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.jboss.system.ServiceMBean
getName, getState, getStateString, jbossInternalLifecycle
 
Methods inherited from interface org.jboss.system.Service
create, destroy, start, stop
 

Constructor Detail

DataSourceInterceptor

public DataSourceInterceptor()
Method Detail

getStatsCollector

public javax.management.ObjectName getStatsCollector()
Specified by:
getStatsCollector in interface DataSourceInterceptorMBean

setStatsCollector

public void setStatsCollector(javax.management.ObjectName statsCollector)
Specified by:
setStatsCollector in interface DataSourceInterceptorMBean

getBindName

public String getBindName()
Specified by:
getBindName in interface DataSourceInterceptorMBean

setBindName

public void setBindName(String bindName)
                 throws NamingException
Specified by:
setBindName in interface DataSourceInterceptorMBean
Throws:
NamingException

getTargetName

public String getTargetName()
Specified by:
getTargetName in interface DataSourceInterceptorMBean

setTargetName

public void setTargetName(String targetName)
                   throws NamingException
Specified by:
setTargetName in interface DataSourceInterceptorMBean
Throws:
NamingException

startService

public void startService()
                  throws Exception
Throws:
Exception

stopService

public void stopService()
                 throws Exception
Throws:
Exception

getLoginTimeout

public int getLoginTimeout()
                    throws SQLException
Specified by:
getLoginTimeout in interface DataSource
Throws:
SQLException

setLoginTimeout

public void setLoginTimeout(int seconds)
                     throws SQLException
Specified by:
setLoginTimeout in interface DataSource
Throws:
SQLException

getLogWriter

public PrintWriter getLogWriter()
                         throws SQLException
Specified by:
getLogWriter in interface DataSource
Throws:
SQLException

setLogWriter

public void setLogWriter(PrintWriter out)
                  throws SQLException
Specified by:
setLogWriter in interface DataSource
Throws:
SQLException

getConnection

public Connection getConnection()
                         throws SQLException
Specified by:
getConnection in interface DataSource
Throws:
SQLException

getConnection

public Connection getConnection(String username,
                                String password)
                         throws SQLException
Specified by:
getConnection in interface DataSource
Throws:
SQLException


Copyright © 2002 JBoss Group, LLC. All Rights Reserved.