org.datanucleus.jdo
Class JDOConnectionImpl

java.lang.Object
  extended by org.datanucleus.jdo.JDOConnectionImpl
All Implemented Interfaces:
javax.jdo.datastore.JDOConnection, NucleusConnection

public final class JDOConnectionImpl
extends java.lang.Object
implements javax.jdo.datastore.JDOConnection, NucleusConnection

Implementation of a generic JDO connection for non-RDBMS datastores. Takes the NucleusConnection as input, providing all behaviour and closure of underlying connections.


Constructor Summary
JDOConnectionImpl(NucleusConnection nconn)
          Constructor taking the underlying NucleusConnection that provides the datastore access.
 
Method Summary
 void close()
          Method to close the connection.
 java.lang.Object getNativeConnection()
          Accessor for the native connection for this datastore.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JDOConnectionImpl

public JDOConnectionImpl(NucleusConnection nconn)
Constructor taking the underlying NucleusConnection that provides the datastore access.

Parameters:
nconn - Underlying connection
Method Detail

close

public void close()
Method to close the connection.

Specified by:
close in interface javax.jdo.datastore.JDOConnection
Specified by:
close in interface NucleusConnection

getNativeConnection

public java.lang.Object getNativeConnection()
Accessor for the native connection for this datastore. For RDBMS this would be a java.sql.Connection, or for db4o an ObjectContainer etc.

Specified by:
getNativeConnection in interface javax.jdo.datastore.JDOConnection
Specified by:
getNativeConnection in interface NucleusConnection
Returns:
The native connection


Copyright © 2010. All Rights Reserved.