org.apache.jetspeed.testhelpers
Class OJBHelper

java.lang.Object
  extended by org.apache.jetspeed.testhelpers.AbstractTestHelper
      extended by org.apache.jetspeed.testhelpers.DatasourceHelper
          extended by org.apache.jetspeed.testhelpers.OJBHelper
All Implemented Interfaces:
TestHelper

public class OJBHelper
extends DatasourceHelper


Field Summary
private  org.springframework.context.support.GenericApplicationContext appCtx
           
private  org.springframework.beans.factory.support.DefaultListableBeanFactory bf
           
static String DATASOURCE_BEAN
           
 
Fields inherited from class org.apache.jetspeed.testhelpers.DatasourceHelper
datasource, DATASOURCE_KEY
 
Fields inherited from class org.apache.jetspeed.testhelpers.AbstractTestHelper
APP_CONTEXT
 
Constructor Summary
OJBHelper(Map context)
           
 
Method Summary
 Object getTxProxiedObject(Object object, String[] interfacesToProxyAs)
          Surrounds the object with TransactionProxyFactoryBean that implements all interfaces specified in interfacesToProxyAs
 void setUp()
           
 void tearDown()
           
 
Methods inherited from class org.apache.jetspeed.testhelpers.AbstractTestHelper
addBeanFactory, getContext, getUserProperty
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DATASOURCE_BEAN

public static final String DATASOURCE_BEAN
See Also:
Constant Field Values

appCtx

private org.springframework.context.support.GenericApplicationContext appCtx

bf

private org.springframework.beans.factory.support.DefaultListableBeanFactory bf
Constructor Detail

OJBHelper

public OJBHelper(Map context)
Method Detail

setUp

public void setUp()
           throws Exception
Specified by:
setUp in interface TestHelper
Overrides:
setUp in class DatasourceHelper
Throws:
Exception

tearDown

public void tearDown()
              throws Exception
Specified by:
tearDown in interface TestHelper
Overrides:
tearDown in class DatasourceHelper
Throws:
Exception

getTxProxiedObject

public Object getTxProxiedObject(Object object,
                                 String[] interfacesToProxyAs)
                          throws Exception
Surrounds the object with TransactionProxyFactoryBean that implements all interfaces specified in interfacesToProxyAs

Parameters:
object - object to wrap with a TX Proxy
interfacesToProxyAs - interfeaces to proxy as
Returns:
Tx Wrapped version of the priginal object
Throws:
Exception


Copyright © 1999-2007 Apache Software Foundation. All Rights Reserved.