Wt (web toolkit) interview Questions for Experienced/Wt (web toolkit) Interview Questions and Answers for Freshers & Experienced

What is DevelopmentModeLogHandler in GWT?

DevelopmentModeLogHandler logs by calling method GWT.log. These messages can only be seen in Development Mode in the DevMode window.

How to enable history support in GWT application?

In order to use GWT History support, we must first embed following iframe into our host HTML page.

<ifram e src="javascript:''" ></ifram e>

What is ConsoleLogHandler in GWT?

ConsoleLogHandler logs to the javascript console, which is used by Firebug Lite (for IE), Safari and Chrome.

What is Dynamic String Internationalization technique in GWT?

This technique is very flexible but slower than static string internationalization. Host page contains the localized strings therefore, applications are not required to be recompiled when we add a new locale. If GWT application is to be integrated with an existing server-side localization system, then this technique is to be used.

What is Static String Internationalization technique in GWT?

This technique is most prevalent and requires very little overhead at runtime; is a very efficient technique for translating both constant and parameterized strings;simplest to implement. Static string internationalization uses standard Java properties files to store translated strings and parameterized messages, and strongly-typed Java interfaces are created to retrieve their values.

Which interface a java data object should implement so that it can be transferred over the wire in GWT RPC?

A java data object should implement isSerializable interface so that it can be transferred over the wire in GWT RPC.

What are the core components of GWT RPC?

Following are the three components used in GWT RPC communication mechanism:

* A remote service server − sideservlet that runs on the server.
* Client code to invoke that service.
* Java data objects which will be passed between client and server.
* GWT client and server both serialize and deserialize data automatically so developers are not required to serialize/deserialize objects and data objects can travel over HTTP.

What is GWT RPC?

* RPC, Remote Procedure Call is the mechansim used by GWT in which client code can directly executes the server side methods.
* GWT RPC is servlet based.
* GWT RPC is asynchronous and client is never blocked during communication.
* Using GWT RPC Java objects can be sent directly between the client and the server whichareautomaticallyserializedbytheGWTframework.
* Server-side servlet is termed as service.
* Remote procedure call that is calling methods of server side servlets from client side code is referred to as invoking a service.

Which GWT widget is the base class for panels that contain only one widget?

SimplePanel is the base class for panels that contain only one widget.

What is Dynamic String Internationalization technique in GWT?

This technique is very flexible but slower than static string internationalization. Host page contains the localized strings therefore, applications are not required to be recompiled when we add a new locale. If GWT application is to be integrated with an existing server-side localization system, then this technique is to be used.

What is Static String Internationalization technique in GWT?

This technique is most prevalent and requires very little overhead at runtime; is a very efficient technique for translating both constant and parameterized strings;simplest to implement. Static string internationalization uses standard Java properties files to store translated strings and parameterized messages, and strongly-typed Java interfaces are created to retrieve their values.

What is internationalization?

Internationalization is a way to show locale specific information on a website. For example, display content of a website in English language in United States and in Danish in France.

Which interface a java data object should implement so that it can be transferred over the wire in GWT RPC?

A java data object should implement isSerializable interface so that it can be transferred over the wire in GWT RPC.

Which GWT widget represents a simple panel that wraps its contents in a scrollable area?

ScrollPanel widget represents a simple panel that wraps its contents in a scrollable area.

Which GWT widget represents a panel that lays all of its widgets out in a single vertical column?

VerticalPanel widget represents a panel that lays all of its widgets out in a single vertical column.

What is VerticalSplitPanel in GWT?

VerticalSplitPanel widget represents a A panel that arranges two widgets in a single vertical column and allows the user to interactively change the proportion of the height dedicated to each of the two widgets. Widgets contained within a VertialSplitPanel will be automatically decorated with scrollbars when necessary.

What is HorizontalSplitPanel in GWT?

HorizontalSplitPanel widget represents a panel that arranges two widgets in a single horizontal row and allows the user to interactively change the proportion of the width dedicated to each of the two widgets. Widgets contained within a HorizontalSplitPanel will be automatically decorated with scrollbars when necessary.

Which GWT widget represents a panel that lays all of its widgets out in a single horizontal column?

HorizontalPanel widget represents a panel that lays all of its widgets out in a single horizontal column.

Which class is the base class of all layout panel classes?

Panel is the abstract base class for all panels, which are widgets that can contain other widgets.

Which GWT widget represents a browsable view of a tree in which only a single node per level may be open at one time?

CellBrowser widget represents a browsable view of a tree in which only a single node per level may be open at one time. This widget will only work in standards mode, which requires that the HTML page in which it is run have an explicit <!DOCTYPE> declaration.

Which GWT widget represents a view of a tree?

CellTree widget represents a view of a tree. This widget will only work in standards mode, which requires that the HTML page in which it is run have an explicit <!DOCTYPE> declaration.

How to create the custom widget?

Google Web Toolkit offers a variety of ways for creating the custom widgets. The easiest way is to develop composite widgets by grouping existing basic widgets and adding some interaction logic to them.

To create a Custom Widget, it has three general concepts which are as follows:

1. Building Composite Widgets.
2. Create the Java Code for the new widget.
3. Wrap JavaScript using JSNI methods.

Define GWT History Tokens.

A token is simply a string that the application can parse to return to a particular state. This token will be saved in browser history as a URL fragment (in the location bar, after the "#"), and this fragment is passed back to the application when the user goes back or forward in history or follows a link.

Which GWT widget represents a browsable view of a tree in which only a single node per level may be open at one time?

CellBrowser widget represents a browsable view of a tree in which only a single node per level may be open at one time. This widget will only work in standards mode, which requires that the HTML page in which it is run have an explicit <!DOCTYPE> declaration.

Which GWT widget represents a standard menu bar?

MenuBar widget represents a standard menu bar widget. A menu bar can contain any number of menu items, each of which can either fire a Command or open a cascaded menu bar.

Which GWT widget represents a standard hierarchical tree?

Tree widget represents a standard hierarchical tree widget. The tree contains a hierarchy of TreeItems that the user can open, close, and select.

What is Gwt Sever Side RemoteServiceServlet?

public class RemoteServiceServlet extends javax.servlet.http.HttpServletimplements SerializationPolicyProvider
The servlet base class for your RPC service implementations that automatically deserializes incoming requests from the client and serializes outgoing responses for client/server RPCs.

Which widget represents a file upload in GWT?

FileUpload widget wraps the HTML <input type='file'> element.

What are the language differences between web mode and hosted mode?

Typically, if your code runs as intended in hosted mode and compiles to JavaScript without error, web mode behavior will be equivalent. Occasional different problems can cause subtle bugs to appear in web mode that don’t appear in hosted mode. Fortunately those cases are rare.

What are Modules, Entry Points and HTML Pages in GWT?

GWT applications are described as modules. A module ”modulename” is described by a configuration file ”modulename.gwt.xml”. Each module can define one or more Entry point classes.

An entry point is the starting point for a GWT application, similar to the main method in a standard Java program. A Java class which is an entry point must implement the interface ”com.google.gwt.core.client.EntryPoint” which defines the method onModuleLoad().
The module is connected to a HTML page, which is called ”host page”. The code for a GWT web application executes within this HTML document.
The HTML page can define ”div” containers to which the GWT application can assign UI components or the GWT UI components are simply assigned to the body tag of the HTML page.

Which GWT widget represents a standard menu bar?

MenuBar widget represents a standard menu bar widget. A menu bar can contain any number of menu items, each of which can either fire a Command or open a cascaded menu bar.

Which GWT widget represents a standard hierarchical tree?

Tree widget represents a standard hierarchical tree widget. The tree contains a hierarchy of TreeItems that the user can open, close, and select.

Which widget represents a password text box in GWT?

PasswordTextBox widget represents a text box that visually masks its input to prevent eavesdropping.

Which widget represents a single line text box in GWT?

TextBox widget represents a single line text box.

Which widget acts as a suggestion box in GWT?

SuggestBox widget represents a text box or text area which displays a pre-configured set of selections that match the user's input. Each SuggestBox is associated with a single SuggestOracle. The SuggestOracle is used to provide a set of selections given a specific query string.

Which widget represents a list of choices to the user, either as a list box or as a drop-down list in GWT?

ListBox widget represents a list of choices to the user, either as a list box or as a drop-down list.

Which widget represents a standard check box widget. This class also serves as a base class for RadioButton in GWT?

CheckBox widget represents a standard check box widget. This class also serves as a base class for RadioButton.

Which widget represents a mutually-exclusive selection radio button widget in GWT?

RadioButton widget represents a mutually-exclusive selection radio button widget.

Which widget represents a stylish stateful button which allows the user to toggle between up and down states in GWT?

ToggleButton widget represents a stylish stateful button which allows the user to toggle between up and down states.

What is the purpose of Label widget of a GWT?

This widget contains text, not interpreted as HTML using a

element, causing it to be displayed with block layout.

How you can attach a CSS file with your GWT module?

There are multiple approaches for associating CSS files with your module. Modern GWT applications typically use a combination of CssResource and UiBinder.

* Using a tag in the host HTML page.
* Using the <stylesheet> element in the module XML file.
* Using a CssResource contained within a ClientBundle.
* Using an inline <ui:style> element in a UiBinder template.

What is the difference between primary style and secondary styles of a GWT Widget?

By default, the primary style name of a widget will be the default style name for its widget class. For example, gwt-Button for Button widgets. When we add and remove style names using AddStyleName method, those styles are called secondary styles.

The final appearance of a widget is determined by the sum of all the secondary styles added to it, plus its primary style. You set the primary style of a widget with the setStylePrimaryNameString method.

What is the purpose of removeStyleName function of a GWT widget?

This method will remove given style from the widget and leaves any others associated with the widget.

What is the purpose of addStyleName function of a GWT widget?

This method will add a secondary or dependent style name to the widget. A secondary style name is an additional style name that is,so if there were any previous style names applied they are kept.

What is the purpose of setStyleName function of a GWT widget?

This method will clear any existing styles and set the widget style to the new CSS class provided using style.

Why doesn’t GWT provide a synchronous server connection option?

GWT’s network operations are all asynchronous, or non-blocking. That is, they return immediately as soon as called, and require the user to use a callback method to handle the results when they are eventually returned from the server. Though in some cases asynchronous operators are less convenient to use than synchronous operators, GWT does not provide synchronous operators.
The reason is that most browsers’ JavaScript engines are single-threaded. As a result, blocking on a call to XMLHTTPRequest also blocks the UI thread, making the browser appear to freeze for the duration of the connection to the server. Some browsers provide a way around this, but there is no universal solution. GWT does not implement a synchronous network connection because to do so would be to introduce a feature that does not work on all browsers, violating GWT’s commitment to no-compromise, cross-browser AJAX. It would also introduce complexity for developers, who would have to maintain two different versions of their communications code in order to handle all browsers.

Do GWT compiler creates default Id attribute for its Widget by default?

No! By default, neither the browser nor GWT creates default id attributes for widgets.

What is the default style name of any GWT widget?

By default, the class name for each component is gwt-<classname>. For example, the Button widget has a default style of gwt-Button and similar way TextBox widgest has a default style of gwt- TextBox.

How can I dynamically fetch JSON feeds from other web domains?

Like all AJAX tools, GWT’s HTTP client and RPC libraries are restricted to only accessing data from the same site where the application was loaded, due to the browser Same Origin Policy. If the application is using JSON, there is a work around to this limitation using a <script> tag (aka JSON-P).

First, we need an external JSON service which can invoke user defined callback functions with the JSON data as argument. An example of such a service is GData’s “alt=json-in-script& callback=myCallback” support. Then, we can use JsonpRequestBuilder to make our call, in a way similar to a RequestBuilder when we’re not making a cross-site request.

Explain UIObject class.

* The class UIObject is the superclass for all user-interface objects. It simply wraps a DOM element, and cannot receive events. It provides direct child classes like Widget, MenuItem, MenuItemSeparator, TreeItem.

* All UIObject objects can be styled using CSS.

* Every UIObject has a primary style name that identifies the key CSS style rule that should always be applied to it.

* More complex styling behavior can be achieved by manipulating an object's secondary style names.

Search
R4R Team
R4R provides Wt (web toolkit) Freshers questions and answers (Wt (web toolkit) Interview Questions and Answers) .The questions on R4R.in website is done by expert team! Mock Tests and Practice Papers for prepare yourself.. Mock Tests, Practice Papers,Wt (web toolkit) interview Questions for Experienced,Wt (web toolkit) Freshers & Experienced Interview Questions and Answers,Wt (web toolkit) Objetive choice questions and answers,Wt (web toolkit) Multiple choice questions and answers,Wt (web toolkit) objective, Wt (web toolkit) questions , Wt (web toolkit) answers,Wt (web toolkit) MCQs questions and answers Java, C ,C++, ASP, ASP.net C# ,Struts ,Questions & Answer, Struts2, Ajax, Hibernate, Swing ,JSP , Servlet, J2EE ,Core Java ,Stping, VC++, HTML, DHTML, JAVASCRIPT, VB ,CSS, interview ,questions, and answers, for,experienced, and fresher R4r provides Python,General knowledge(GK),Computer,PHP,SQL,Java,JSP,Android,CSS,Hibernate,Servlets,Spring etc Interview tips for Freshers and Experienced for Wt (web toolkit) fresher interview questions ,Wt (web toolkit) Experienced interview questions,Wt (web toolkit) fresher interview questions and answers ,Wt (web toolkit) Experienced interview questions and answers,tricky Wt (web toolkit) queries for interview pdf,complex Wt (web toolkit) for practice with answers,Wt (web toolkit) for practice with answers You can search job and get offer latters by studing r4r.in .learn in easy ways .