Examples of ConnectionHandle


Examples of com.jolbox.bonecp.ConnectionHandle

    CopyManager manager = null;
    try {
      con = this.getConnection();
      con.setAutoCommit(false);
      if(con instanceof com.jolbox.bonecp.ConnectionHandle){
        ConnectionHandle handle = (ConnectionHandle)con;
        manager = new CopyManager(
            (BaseConnection) handle.getInternalConnection());
      } else {
        manager = new CopyManager((BaseConnection) con);
      }
     
      manager.copyIn(query, reader);
View Full Code Here

Examples of com.jolbox.bonecp.ConnectionHandle

*/
public class BoneCPConnectionAccessor implements ConnectionAccessor {

    @Override
    public Connection getRawConnection(Connection providerConnection) {
        ConnectionHandle ch = (ConnectionHandle) providerConnection;
        return ch.getInternalConnection();
    }
View Full Code Here

Examples of com.jolbox.bonecp.ConnectionHandle

        return mockStmt;
    }

    public static MockConnection unwrap(Connection conn) throws Exception {
        if (conn instanceof ConnectionHandle) {
            ConnectionHandle handle = (ConnectionHandle) conn;
            return (MockConnection) handle.getInternalConnection();
        }
        if (conn instanceof NewProxyConnection) {
            NewProxyConnection handle = (NewProxyConnection) conn;

            Field field = NewProxyConnection.class.getDeclaredField("inner");
View Full Code Here

Examples of com.jolbox.bonecp.ConnectionHandle

        }
    }

    public static MockConnection unwrap(Connection conn) throws Exception {
        if (conn instanceof ConnectionHandle) {
            ConnectionHandle handle = (ConnectionHandle) conn;
            return (MockConnection) handle.getInternalConnection();
        }
        if (conn instanceof NewProxyConnection) {
            NewProxyConnection handle = (NewProxyConnection) conn;
           
            Field field = NewProxyConnection.class.getDeclaredField("inner");
View Full Code Here

Examples of com.ti.eps.navnet.ConnectionHandle

        if (calcHandle != null) {
            NspireVirtualKeyStroke key = (NspireVirtualKeyStroke) event;
            byte[] keyBytesCode = key.getKeyCode();

            if (keyBytesCode != null) {
                ConnectionHandle ch = new ConnectionHandle();
                status = NavNet.connect(calcHandle, 16450, ch);

                if (status == 1) {
                    status = NavNet.write(ch, NspireVirtualKeyStroke.VIRTUAL_KEY_STROKE_EVENT_COMMAND, NspireVirtualKeyStroke.VIRTUAL_KEY_STROKE_EVENT_COMMAND.length);
View Full Code Here

Examples of com.ti.eps.navnet.ConnectionHandle

    public static int sendKeyBytesToNode(NodeHandle calcHandle, byte[] keyBytesCode)
            throws Exception {
        int status = 0;
        if (calcHandle != null) {
            if (keyBytesCode != null) {
                ConnectionHandle ch = new ConnectionHandle();
                status = NavNet.connect(calcHandle, 16450, ch);

                if (status == 1) {
                    status = NavNet.write(ch, NspireVirtualKeyStroke.VIRTUAL_KEY_STROKE_EVENT_COMMAND, NspireVirtualKeyStroke.VIRTUAL_KEY_STROKE_EVENT_COMMAND.length);
View Full Code Here

Examples of org.springframework.jdbc.datasource.ConnectionHandle

        txObject.getEntityManagerHolder().setTimeoutInSeconds(timeout);
      }

      // Register the JPA EntityManager's JDBC Connection for the DataSource, if set.
      if (getDataSource() != null) {
        ConnectionHandle conHandle = getJpaDialect().getJdbcConnection(em, definition.isReadOnly());
        if (conHandle != null) {
          ConnectionHolder conHolder = new ConnectionHolder(conHandle);
          if (timeout != TransactionDefinition.TIMEOUT_DEFAULT) {
            conHolder.setTimeoutInSeconds(timeout);
          }
View Full Code Here

Examples of org.springframework.jdbc.datasource.ConnectionHandle

        txObject.getEntityManagerHolder().setTimeoutInSeconds(timeout);
      }

      // Register the JPA EntityManager's JDBC Connection for the DataSource, if set.
      if (getDataSource() != null) {
        ConnectionHandle conHandle = getJpaDialect().getJdbcConnection(em, definition.isReadOnly());
        if (conHandle != null) {
          ConnectionHolder conHolder = new ConnectionHolder(conHandle);
          if (timeout != TransactionDefinition.TIMEOUT_DEFAULT) {
            conHolder.setTimeoutInSeconds(timeout);
          }
View Full Code Here

Examples of org.springframework.jdbc.datasource.ConnectionHandle

        txObject.getEntityManagerHolder().setTimeoutInSeconds(timeoutToUse);
      }

      // Register the JPA EntityManager's JDBC Connection for the DataSource, if set.
      if (getDataSource() != null) {
        ConnectionHandle conHandle = getJpaDialect().getJdbcConnection(em, definition.isReadOnly());
        if (conHandle != null) {
          ConnectionHolder conHolder = new ConnectionHolder(conHandle);
          if (timeoutToUse != TransactionDefinition.TIMEOUT_DEFAULT) {
            conHolder.setTimeoutInSeconds(timeoutToUse);
          }
View Full Code Here

Examples of org.springframework.jdbc.datasource.ConnectionHandle

        txObject.getPersistenceManagerHolder().setTimeoutInSeconds(timeout);
      }

      // Register the JDO PersistenceManager's JDBC Connection for the DataSource, if set.
      if (getDataSource() != null) {
        ConnectionHandle conHandle = getJdoDialect().getJdbcConnection(pm, definition.isReadOnly());
        if (conHandle != null) {
          ConnectionHolder conHolder = new ConnectionHolder(conHandle);
          if (timeout != TransactionDefinition.TIMEOUT_DEFAULT) {
            conHolder.setTimeoutInSeconds(timeout);
          }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.