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

## org.mortbay.util.ajax
Class WaitingContinuation

    java.lang.Object
      org.mortbay.util.ajax.WaitingContinuation

All Implemented Interfaces:
  Continuation

    public class WaitingContinuation

extends Object
implements Continuation

Constructor Summary
`WaitingContinuation()`
`WaitingContinuation(Object mutex)`

Method Summary
`Object` | `getMutex()`
`Object` | `getObject()` Arbitrary object associated with the continuation for context.
`boolean` | `isNew()` Is this a newly created Continuation.
`boolean` | `isPending()` Get the pending status? A continuation is pending while the handling of a call to suspend has not completed.
`boolean` | `isResumed()` Get the resumed status?
`void` | `reset()` Reset the continuation.
`void` | `resume()` Resume the request.
`void` | `setMutex(Object mutex)`
`void` | `setObject(Object object)` Arbitrary object associated with the continuation for context.
`boolean` | `suspend(long timeout)` Suspend handling.

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

Constructor Detail

### WaitingContinuation

    public WaitingContinuation()

### WaitingContinuation

    public WaitingContinuation(Object mutex)

Method Detail

### resume

    public void resume()

  Description copied from interface: `Continuation`
  Resume the request. Resume a suspended request. The passed event will be returned in the getObject method.

  Specified by:
    `resume` in interface `Continuation`

### reset

    public void reset()

  Description copied from interface: `Continuation`
  Reset the continuation. Cancel any pending status of the continuation.

  Specified by:
    `reset` in interface `Continuation`

### isNew

    public boolean isNew()

  Description copied from interface: `Continuation`
  Is this a newly created Continuation.

  A newly created continuation has not had `#getEvent(long)` called on it.

  Specified by:
    `isNew` in interface `Continuation`
  Returns:
    True if the continuation has just been created and has not yet suspended the request.

### suspend

    public boolean suspend(long timeout)

  Description copied from interface: `Continuation`
  Suspend handling. This method will suspend the request for the timeout or until resume is called.

  Specified by:
    `suspend` in interface `Continuation`
  Returns:
    True if resume called or false if timeout.

### isPending

    public boolean isPending()

  Description copied from interface: `Continuation`
  Get the pending status? A continuation is pending while the handling of a call to suspend has not completed. For blocking continuations, pending is true only during the call to `Continuation.suspend(long)`. For non-blocking continuations, pending is true until a second call to `Continuation.suspend(long)`, thus this method can be used to determine if a request is being retried.

  Specified by:
    `isPending` in interface `Continuation`
  Returns:
    True if the continuation is handling a call to suspend.

### isResumed

    public boolean isResumed()

  Description copied from interface: `Continuation`
  Get the resumed status?

  Specified by:
    `isResumed` in interface `Continuation`
  Returns:
    True if the continuation is has been resumed.

### getObject

    public Object getObject()

  Description copied from interface: `Continuation`
  Arbitrary object associated with the continuation for context.

  Specified by:
    `getObject` in interface `Continuation`
  Returns:
    An arbitrary object associated with the continuation

### setObject

    public void setObject(Object object)

  Description copied from interface: `Continuation`
  Arbitrary object associated with the continuation for context.

  Specified by:
    `setObject` in interface `Continuation`
  Parameters:
    `object` - An arbitrary object to associate with the continuation

### getMutex

    public Object getMutex()

### setMutex

    public void setMutex(Object mutex)

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

Copyright © 2007 Mort Bay Consulting. All Rights Reserved.