Package javax.resource.cci

Examples of javax.resource.cci.Interaction.execute()


    given(connectionFactory.getRecordFactory()).willReturn(recordFactory);
    given(callDetector.callCreateInputRecord(recordFactory, inObj)).willReturn(inputRecord);
    given(connectionFactory.getConnection()).willReturn(connection);
    given(connection.createInteraction()).willReturn(interaction);
    given(interaction.execute(interactionSpec, inputRecord)).willReturn(outputRecord);
    given(callDetector.callExtractOutputData(outputRecord)).willReturn(outObj);

    assertSame(outObj, query.execute(inObj));
    verify(interaction).close();
    verify(connection).close();
View Full Code Here


    given(callDetector.callCreateInputRecord(recordFactory, inObj)).willReturn(inputRecord);
    given(connectionFactory.getConnection()).willReturn(connection);
    given(connection.createInteraction()).willReturn(interaction);
    given(connectionFactory.getRecordFactory()).willReturn(recordFactory);
    given(outputCreator.createRecord(recordFactory)).willReturn(outputRecord);
    given(interaction.execute(interactionSpec, inputRecord, outputRecord)).willReturn(true);
    given(callDetector.callExtractOutputData(outputRecord)).willReturn(outObj);

    assertSame(outObj, query.execute(inObj));
    verify(interaction).close();
    verify(connection).close();
View Full Code Here

    final InteractionSpec interactionSpec = mock(InteractionSpec.class);

    given(connectionFactory.getConnection()).willReturn(connection);
    given(connection.getLocalTransaction()).willReturn(localTransaction);
    given(connection.createInteraction()).willReturn(interaction);
    given(interaction.execute(interactionSpec, record, record)).willReturn(true);
    given(connection.getLocalTransaction()).willReturn(localTransaction);

    CciLocalTransactionManager tm = new CciLocalTransactionManager();
    tm.setConnectionFactory(connectionFactory);
    TransactionTemplate tt = new TransactionTemplate(tm);
View Full Code Here

    final InteractionSpec interactionSpec = mock(InteractionSpec.class);

    given(connectionFactory.getConnection()).willReturn(connection);
    given(connection.getLocalTransaction()).willReturn(localTransaction);
    given(connection.createInteraction()).willReturn(interaction);
    given(interaction.execute(interactionSpec, record, record)).willReturn(true);
    given(connection.getLocalTransaction()).willReturn(localTransaction);

    CciLocalTransactionManager tm = new CciLocalTransactionManager();
    tm.setConnectionFactory(connectionFactory);
    TransactionTemplate tt = new TransactionTemplate(tm);
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.