Oracle ADF Model and Business Components API Reference 10.1.2 B14022-01

oracle.adf.model.binding
Interface DCDataControlManagement

All Known Implementing Classes:
DCDataControl, DCDataControlReference

public interface DCDataControlManagement

INTERNAL USE ONLY. This interface should not be implemented directly by any applications.

An interface for DataControl management events.

This interface is implemented by both the DCDataControl and the DCDataControlReference classes. It allows both to be notified of DataControl management events.


Method Summary
 void beginRequest(java.util.HashMap requestCtx)
          Invoked in some contexts to signal the beginning of a model request.
 void endRequest(java.util.HashMap requestCtx)
          Invoked in some contexts to signal the end of a model request.
 void release()
           
 void release(int flags)
          Based on the value of the flags parameter, releases all references to the objects in the data provider layer (BC4J or other data-provider objects).
 boolean resetState()
          Resets the DataControl.
 

Method Detail

beginRequest

public void beginRequest(java.util.HashMap requestCtx)
Invoked in some contexts to signal the beginning of a model request. For example, if the DataControl is referenced in a web application then this method will be invoked by the ADF framework before control is forwarded to the first Servlet defined by the request.

Subclassing datacontrols may extend this method to perform request level initialization of the DataControl.

This method is guaranteed to be called only once per browser request. Page forwards should not result in multiple invocations.

Parameters:
requestCtx - a HashMap representing request context. Web applications which require request context may use the BindingContext.HTTP_REQUEST and BindingContext.HTTP_RESPONSE keys to acquire a reference from from the BindingContext.

endRequest

public void endRequest(java.util.HashMap requestCtx)
Invoked in some contexts to signal the end of a model request. For example, if the DataControl is referenced in a web application then this method will be invoked by the ADF framework after control is returned from the last Servlet defined by the request page flow.

Subclassing datacontrols may extend this method to perform request level cleanup of the DataControl.

This method is guaranteed to be called only once per browser request. Page forwards should not result in multiple invocations.

Parameters:
requestCtx - a HashMap representing request context. Web applications which require request context may use the BindingContext.HTTP_REQUEST and BindingContext.HTTP_RESPONSE keys to acquire a reference from from the BindingContext.

release

public void release(int flags)
Based on the value of the flags parameter, releases all references to the objects in the data provider layer (BC4J or other data-provider objects). Valid values for flags are:


release

public void release()

resetState

public boolean resetState()
Resets the DataControl. DataControl providers should extend this method to reset any model session state that may have been managed by this DataControl. For example:

The ADF/BC DataControl has extended resetState to release the DataControl ApplicationModule to the ApplicationPool in unmanaged release mode.

An EJB DataControl provider may extend resetState to close the DataControl EJB SessionBean

A Toplink DataControl provider may extend resetState to close the DataControl UnitOfWork or ClientSession.

Please note that resetState may not occur immediately. If beginRequest has been invoked on the DataControl then resetState processing will be deferred until endRequest processing.

Extending DataControl providers should invoke release(REL_DATA_REFS) after performing and DataControl specific resetState handling.

Returns:
true if resetState was processed immediately. false if resetState was deferred to endRequest processing.

Oracle ADF Model and Business Components API Reference 10.1.2 B14022-01

 

Copyright © 1997, 2004, Oracle. All rights reserved.