Package javax.resource.cci

Examples of javax.resource.cci.Record


  public void testSimpleRecordOperationWithInputOutputRecord() throws ResourceException {
    ConnectionFactory connectionFactory = mock(ConnectionFactory.class);
    Connection connection = mock(Connection.class);
    Interaction interaction = mock(Interaction.class);

    Record inputOutputRecord = mock(Record.class);

    InteractionSpec interactionSpec = mock(InteractionSpec.class);

    SimpleRecordOperation query = new SimpleRecordOperation(connectionFactory, interactionSpec);
View Full Code Here


    ConnectionFactory connectionFactory = mock(ConnectionFactory.class);
    Connection connection = mock(Connection.class);
    Interaction interaction = mock(Interaction.class);
    RecordFactory recordFactory = mock(RecordFactory.class);

    Record inputRecord = mock(Record.class);
    Record outputRecord = mock(Record.class);

    InteractionSpec interactionSpec = mock(InteractionSpec.class);

    QueryCallDetector callDetector = mock(QueryCallDetector.class);
View Full Code Here

    ConnectionFactory connectionFactory = mock(ConnectionFactory.class);
    Connection connection = mock(Connection.class);
    Interaction interaction = mock(Interaction.class);
    RecordFactory recordFactory = mock(RecordFactory.class);

    Record inputRecord = mock(Record.class);
    Record outputRecord = mock(Record.class);

    RecordCreator outputCreator = mock(RecordCreator.class);

    InteractionSpec interactionSpec = mock(InteractionSpec.class);
View Full Code Here

  public void testLocalTransactionCommit() throws ResourceException {
    final ConnectionFactory connectionFactory = mock(ConnectionFactory.class);
    Connection connection = mock(Connection.class);
    Interaction interaction = mock(Interaction.class);
    LocalTransaction localTransaction = mock(LocalTransaction.class);
    final Record record = mock(Record.class);
    final InteractionSpec interactionSpec = mock(InteractionSpec.class);

    given(connectionFactory.getConnection()).willReturn(connection);
    given(connection.getLocalTransaction()).willReturn(localTransaction);
    given(connection.createInteraction()).willReturn(interaction);
View Full Code Here

  public void testLocalTransactionRollback() throws ResourceException {
    final ConnectionFactory connectionFactory = mock(ConnectionFactory.class);
    Connection connection = mock(Connection.class);
    Interaction interaction = mock(Interaction.class);
    LocalTransaction localTransaction = mock(LocalTransaction.class);
    final Record record = mock(Record.class);
    final InteractionSpec interactionSpec = mock(InteractionSpec.class);

    given(connectionFactory.getConnection()).willReturn(connection);
    given(connection.getLocalTransaction()).willReturn(localTransaction);
    given(connection.createInteraction()).willReturn(interaction);
View Full Code Here

      final RecordExtractor<T> outputExtractor) throws DataAccessException {

    return execute(new InteractionCallback<T>() {
      public T doInInteraction(Interaction interaction, ConnectionFactory connectionFactory)
          throws ResourceException, SQLException, DataAccessException {
        Record outputRecordToUse = outputRecord;
        try {
          if (outputRecord != null || getOutputRecordCreator() != null) {
            // Use the CCI execute method with output record as parameter.
            if (outputRecord == null) {
              RecordFactory recordFactory = getRecordFactory(connectionFactory);
View Full Code Here

TOP

Related Classes of javax.resource.cci.Record

Copyright © 2018 www.massapicom. 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.