Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.cayenne.access
Class DataDomainLegacyQueryAction

    java.lang.Object
      org.apache.cayenne.access.DataDomainLegacyQueryAction

All Implemented Interfaces:
  OperationHints, OperationObserver, QueryRouter

    public class DataDomainLegacyQueryAction

extends java.lang.Object
implements QueryRouter, OperationObserver

DataDomain query action that relies on expernally provided OperationObserver to process the results.

Since:
  1.2
Author:
  Andrus Adamchik

Method Summary
`QueryEngine` | `engineForDataMap(DataMap map)` Returns a QueryEngine that is configured to handle a given DataMap.
`org.apache.log4j.Level` | `getLoggingLevel()` Deprecated. since 1.2, as corresponding interface method is deprecated too.
`boolean` | `isIteratedResult()` Returns `true` to indicate that any results of a select operation should be returned as a ResultIterator.
`void` | `nextBatchCount(Query query, int[] resultCount)` Callback method invoked after a batch update is executed.
`void` | `nextCount(Query query, int resultCount)` Callback method invoked after an updating query is executed.
`void` | `nextDataRows(Query query, java.util.List dataRows)` Callback method invoked for each processed ResultSet.
`void` | `nextDataRows(Query q, ResultIterator it)` Callback method invoked for each opened ResultIterator.
`void` | `nextGeneratedDataRows(Query query, ResultIterator keysIterator)` Callback method invoked after each batch of generated values is read durring an update.
`void` | `nextGlobalException(java.lang.Exception e)` Callback method invoked on exceptions that are not tied to a specific query execution, such as JDBC connection exceptions, etc.
`void` | `nextQueryException(Query query, java.lang.Exception ex)` Callback method invoked on exceptions that happen during an execution of a specific query.
`void` | `route(QueryEngine engine, Query query, Query substitutedQuery)` A callback method that allows a query to set its preferred engine during the routing phase.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Method Detail

### route

    public void route(QueryEngine engine,
                      Query query,
                      Query substitutedQuery)

  Description copied from interface: `QueryRouter`
  A callback method that allows a query to set its preferred engine during the routing phase. It allows query to further customize its routing, e.g. it is possible to implement query chains that pass multiple queries for execution.

  Specified by:
    `route` in interface `QueryRouter`
  Parameters:
    `engine` - engine to use for query execution
    `query` - A query to execute.
    `substitutedQuery` - a query that was substituted for "query". Results must be mapped back to substituted query.

### engineForDataMap

    public QueryEngine engineForDataMap(DataMap map)

  Description copied from interface: `QueryRouter`
  Returns a QueryEngine that is configured to handle a given DataMap.

  Specified by:
    `engineForDataMap` in interface `QueryRouter`

### nextCount

    public void nextCount(Query query,
                          int resultCount)

  Description copied from interface: `OperationObserver`
  Callback method invoked after an updating query is executed.

  Specified by:
    `nextCount` in interface `OperationObserver`

### nextBatchCount

    public void nextBatchCount(Query query,
                               int[] resultCount)

  Description copied from interface: `OperationObserver`
  Callback method invoked after a batch update is executed.

  Specified by:
    `nextBatchCount` in interface `OperationObserver`

### nextDataRows

    public void nextDataRows(Query query,
                             java.util.List dataRows)

  Description copied from interface: `OperationObserver`
  Callback method invoked for each processed ResultSet.

  Specified by:
    `nextDataRows` in interface `OperationObserver`

### nextDataRows

    public void nextDataRows(Query q,
                             ResultIterator it)

  Description copied from interface: `OperationObserver`
  Callback method invoked for each opened ResultIterator. If this observer requested results to be returned as a ResultIterator, this method is invoked instead of "nextDataRows(Query,List)". OperationObserver is responsible for closing the ResultIterators passed via this method.

  Specified by:
    `nextDataRows` in interface `OperationObserver`

### nextGeneratedDataRows

    public void nextGeneratedDataRows(Query query,
                                      ResultIterator keysIterator)

  Description copied from interface: `OperationObserver`
  Callback method invoked after each batch of generated values is read durring an update.

  Specified by:
    `nextGeneratedDataRows` in interface `OperationObserver`

### nextQueryException

    public void nextQueryException(Query query,
                                   java.lang.Exception ex)

  Description copied from interface: `OperationObserver`
  Callback method invoked on exceptions that happen during an execution of a specific query.

  Specified by:
    `nextQueryException` in interface `OperationObserver`

### nextGlobalException

    public void nextGlobalException(java.lang.Exception e)

  Description copied from interface: `OperationObserver`
  Callback method invoked on exceptions that are not tied to a specific query execution, such as JDBC connection exceptions, etc.

  Specified by:
    `nextGlobalException` in interface `OperationObserver`

### getLoggingLevel

    public org.apache.log4j.Level getLoggingLevel()

  Deprecated. since 1.2, as corresponding interface method is deprecated too.

  Specified by:
    `getLoggingLevel` in interface `OperationHints`

### isIteratedResult

    public boolean isIteratedResult()

  Description copied from interface: `OperationHints`
  Returns `true` to indicate that any results of a select operation should be returned as a ResultIterator. `false` is returned when the results are expected as a list.

  Specified by:
    `isIteratedResult` in interface `OperationHints`

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2001-2006 Apache.org All Rights Reserved.