Skip navigation links

Oracle Fusion Middleware Java API Reference for Oracle ADF Faces
11g Release 1 (11.1.1)
E10684-02


oracle.adf.view.rich.model
Class AsyncFetcher

java.lang.Object
  extended by oracle.adf.view.rich.model.AsyncFetcher


public abstract class AsyncFetcher
extends java.lang.Object

Class vended by AsyncFetch for performing data fetch operations off of the Request thread.

See Also:
AsyncFetch

Constructor Summary
AsyncFetcher()
           

 

Method Summary
abstract  java.lang.Object fetch(AsyncFetch model, java.lang.Object fetchConstraint)
          Tells the model to fetch the data specified by the fetchConstraint.
abstract  boolean isFetched(AsyncFetch model, java.lang.Object fetchConstraint)
          Returns true if the fetchConstraint is of a type supported by the model and all of the data specified by the fetchConstraint is either in memory or unavailable for fetching.

 

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

 

Constructor Detail

AsyncFetcher

public AsyncFetcher()

Method Detail

isFetched

public abstract boolean isFetched(AsyncFetch model,
                                  java.lang.Object fetchConstraint)
Returns true if the fetchConstraint is of a type supported by the model and all of the data specified by the fetchConstraint is either in memory or unavailable for fetching. An example where the data is unavailable would be a fetchConstraint that specified a row index beyond the model's row count.

If determining whether the fetchConstraint is cached in memory is extremely expensive, the implementation should return false.

Parameters:
model - AsyncFetch model to ask if the fetchConstraint is already available in memory
fetchConstraint - constraint specifying which data to fetch
Returns:
true if the fetchConstraint is already available in memory for this model.
See Also:
fetch(oracle.adf.view.rich.model.AsyncFetch, java.lang.Object)

fetch

public abstract java.lang.Object fetch(AsyncFetch model,
                                       java.lang.Object fetchConstraint)
                                throws java.lang.InterruptedException
Tells the model to fetch the data specified by the fetchConstraint. This data will subsequently be accessed on the request thread.

The method will not return until all rows in the range have been fetched and cached.

This method may be called on a non-Request thread and the FacesContext may not be available.

Parameters:
model - AsyncFetch model to fetch the data from
fetchConstraint - Constraint specifying which data to fetch
Returns:
the number of Objects in the specified range that are now available
Throws:
java.lang.InterruptedException
See Also:
isFetched(oracle.adf.view.rich.model.AsyncFetch, java.lang.Object)

Skip navigation links

Oracle Fusion Middleware Java API Reference for Oracle ADF Faces
11g Release 1 (11.1.1)
E10684-02


Copyright (c) 1998, 2008, Oracle and/or its affiliates. All rights reserved.