net.sf.jportlet.service.jdbc
Class JDBCServiceImpl

java.lang.Object
  |
  +--net.sf.jportlet.service.PortletServiceAdapter
        |
        +--net.sf.jportlet.service.jdbc.JDBCServiceImpl
All Implemented Interfaces:
JDBCService, PortletService

public class JDBCServiceImpl
extends PortletServiceAdapter
implements JDBCService

Implementation of JDBCService.

Author:
Herve Tchepannou

Field Summary
 
Fields inherited from class net.sf.jportlet.service.PortletServiceAdapter
_log, _serviceConfig, _serviceContext
 
Fields inherited from interface net.sf.jportlet.service.jdbc.JDBCService
NAME
 
Constructor Summary
JDBCServiceImpl()
           
 
Method Summary
 java.sql.Connection getConnection()
          Returns a SQL connection
 java.lang.String getServiceName()
          Returns the name of the service
 void init(net.sf.jportlet.service.PortletServiceConfig serviceConfig)
          Initialize the service
 
Methods inherited from class net.sf.jportlet.service.PortletServiceAdapter
destroy, getInitParameter, getInitParameter, getServiceConfig
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface net.sf.jportlet.service.PortletService
destroy, getServiceConfig
 

Constructor Detail

JDBCServiceImpl

public JDBCServiceImpl()
Method Detail

getConnection

public java.sql.Connection getConnection()
                                  throws javax.naming.NamingException,
                                         java.sql.SQLException
Description copied from interface: JDBCService
Returns a SQL connection

Specified by:
getConnection in interface JDBCService
Returns:
Connection
Throws:
javax.naming.NamingException - if the JNDI name of the javax.sql.DataSource is invalid
java.sql.SQLException - if any SQL error
See Also:
JDBCService.getConnection()

init

public void init(net.sf.jportlet.service.PortletServiceConfig serviceConfig)
          throws PortletServiceException
Description copied from interface: PortletService
Initialize the service

Specified by:
init in interface PortletService
Overrides:
init in class PortletServiceAdapter
Parameters:
serviceConfig - configuration of the service
PortletServiceException
See Also:
PortletService.init(net.sf.jportlet.service.PortletServiceConfig)

getServiceName

public java.lang.String getServiceName()
Description copied from interface: PortletService
Returns the name of the service

Specified by:
getServiceName in interface PortletService
Returns:
String
See Also:
PortletService.getServiceName()


Copyright © 2002 Herve Tchepannou. All Rights Reserved.