TaskOptions (Google App Engine API for Java)

com.google.appengine.api.taskqueue

Class TaskOptions

  • java.lang.Object
    • com.google.appengine.api.taskqueue.TaskOptions
  • All Implemented Interfaces:
    java.io.Serializable


    public final class TaskOptions
    extends java.lang.Object
    implements java.io.Serializable
    Contains various options for a task following the builder pattern. Calls to TaskOptions methods may be chained to specify multiple options in the one TaskOptions object.

    taskOptions can have either TaskOptions.Method PULL or a PUSH-related method, e.g. POST, GET, ... Tasks with PULL method can only be added into a PULL queue and PUSH tasks can only be added into a PUSH queue.

    Notes on usage:
    The recommended way to instantiate a TaskOptions object is to statically import TaskOptions.Builder.* and invoke a static creation method followed by an instance mutator (if needed):

     import static com.google.appengine.api.taskqueue.TaskOptions.Builder.*;
    
     ...
     QueueFactory.getDefaultQueue().add(withUrl(url).etaMillis(eta));
     
    See Also:
    Serialized Form