Skip navigation links

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


oracle.adf.view.rich.context
Class DoableContextChange

java.lang.Object
  extended by oracle.adf.view.rich.context.ApplicationContextChange
      extended by oracle.adf.view.rich.context.DoableContextChange


public abstract class DoableContextChange
extends ApplicationContextChange

ApplicationContextChange designed to both has suspending and resuming the change as well as implementing the change after the DoableContextChange is created. The Basic order is:

After creation, suspend, resume and undoChange will throw IllegalStateExceptions until the DoableContextChange is initialized by calling doChange()

This calls takes care of tracking the valid states so that doChange() or undoChange() are never called multiple times back-to-back.

See Also:
doChange(javax.faces.context.FacesContext), undoChange(javax.faces.context.FacesContext)

Constructor Summary
DoableContextChange()
           

 

Method Summary
 void doChange(javax.faces.context.FacesContext context)
          Apply the change.
protected abstract  void doChangeImpl(javax.faces.context.FacesContext context)
          Implementation of code to apply the change
 void resume(javax.faces.context.FacesContext context)
          Resume a currently suspended context change.
 void suspend(javax.faces.context.FacesContext context)
          Suspend the context change and revert back to the application context that existed before this context change was originally made.
 void undoChange(javax.faces.context.FacesContext context)
          Undo the change.
protected abstract  void undoChangeImpl(javax.faces.context.FacesContext context)
          Implementation of code to undo the change

 

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

 

Constructor Detail

DoableContextChange

public DoableContextChange()

Method Detail

suspend

public final void suspend(javax.faces.context.FacesContext context)
                   throws java.lang.IllegalStateException
Suspend the context change and revert back to the application context that existed before this context change was originally made.

It's only valid to suspend a context change that's currently active. The implementation of this method does not need to support a call to suspend a context change that's already suspended.

Specified by:
suspend in class ApplicationContextChange
Parameters:
context - the FacesContext for the current request.
Throws:
java.lang.IllegalStateException - if the context change is already suspended or was never initialized

resume

public final void resume(javax.faces.context.FacesContext context)
                  throws java.lang.IllegalStateException
Resume a currently suspended context change.
Specified by:
resume in class ApplicationContextChange
Parameters:
context - the FacesContextfor the current request.
Throws:
java.lang.IllegalStateException - if the context change is not currently suspended or initialized,

doChange

public final void doChange(javax.faces.context.FacesContext context)
                    throws java.lang.IllegalStateException
Apply the change.
Parameters:
context - Current FacesContext
Throws:
java.lang.IllegalStateException - if called on a suspended change

undoChange

public final void undoChange(javax.faces.context.FacesContext context)
Undo the change.
Parameters:
context - Current FacesContext
Throws:
java.lang.IllegalStateException - if called on a suspended or uninitialized change

doChangeImpl

protected abstract void doChangeImpl(javax.faces.context.FacesContext context)
Implementation of code to apply the change
Parameters:
context - Current FacesContext

undoChangeImpl

protected abstract void undoChangeImpl(javax.faces.context.FacesContext context)
Implementation of code to undo the change
Parameters:
context - Current FacesContext

Skip navigation links

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


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