That's because this is implementing the Builder pattern:
http://en.wikipedia.org/wiki/Builder_pattern

<http://en.wikipedia.org/wiki/Builder_pattern>Try this instead:

TaskOptions.Builder.param("start", "0").param("end", 15);

Each builder method returns an instance of the latest Builder object,
constructing the object on the .to() call.


On Thu, Feb 25, 2010 at 1:25 PM, oceandrive <rams...@gmail.com> wrote:

> I wanted to use Queue tasks on my GAE application.
> I need to pass two parameters to my URL servlet /runTasks. So i am
> doing this.
> But when I print the values for start and end, it prints null for
> start and 15 for end.
> Am i doing anything wrong? Is this the right way to pass the
> parameters?
>
> TaskOptions to = null;
> to = TaskOptions.Builder.param("start", "0");
> to = TaskOptions.Builder.param("end", "15");
> to = to.url("/runTasks");
> queue.add(to);
>
> Thanks for the help
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google App Engine for Java" group.
> To post to this group, send email to
> google-appengine-j...@googlegroups.com.
> To unsubscribe from this group, send email to
> google-appengine-java+unsubscr...@googlegroups.com<google-appengine-java%2bunsubscr...@googlegroups.com>
> .
> For more options, visit this group at
> http://groups.google.com/group/google-appengine-java?hl=en.
>
>


-- 
Ikai Lan
Developer Programs Engineer, Google App Engine
http://googleappengine.blogspot.com | http://twitter.com/app_engine

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine for Java" group.
To post to this group, send email to google-appengine-j...@googlegroups.com.
To unsubscribe from this group, send email to 
google-appengine-java+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en.

Reply via email to