Interviewer And Interviewee Guide

EXT-GWT Interview Question:

Explain Code of entry point with onModuleLoad where split out is working?

Submitted by: Administrator
To split your code, simply insert calls to the method GWT.runAsync at the places where you want the program to be able to pause for downloading more code. These locations are called split points. For this you should use runAsync.

public class Hello implements EntryPoint {
public void onModuleLoad() {
Button b = new Button("Click me", new ClickHandler() {
public void onClick(ClickEvent event) {
GWT.runAsync(new RunAsyncCallback() {
public void onFailure(Throwable caught) {
Window.alert("Code download failed");
}

public void onSuccess() {
Window.alert("Hello, AJAX");
}
});
}
});

RootPanel.get().add(b);
}
}
Submitted by: Administrator

Read Online EXT-GWT Job Interview Questions And Answers
Copyright 2007-2024 by Interview Questions Answers .ORG All Rights Reserved.
https://InterviewQuestionsAnswers.ORG.