GWT-One RPC after another
How do i make sure that i can make an RPC call only after i finish the first RPC call?Also how do i make sure that i can refresh my view only after i finish an RPC call.
I know i can do it in the OnSuccess method,but apart from that is there something which i can work with?
I have made significant research on this and also saw开发者_运维问答 that i can use a Timer,but i feel its a heavyweight on client side.
Can i use Scheduler.scheduleDeferred to defer my second rpc call ??
Thanks
Basically you would have 2 RPC callbacks. First RPC callback onSuccess would issue the second RPC call. Second RPC callback onSuccess is a place where you should 'refresh' your page.
Using timers is definitely not a good practice for this task.
精彩评论