Web Technologies - Asses2-1
Web Technologies - Asses2-1
2
DOM Elements using Java Script 3 2
What are the two ways to
3
implement thread in Java? 2
Describe the differences between client/server interactions
traditional web in 2
applications and client/server interactions in Ajax web
Howto implement session tracking for applications.
5 Draw the lifecycle of JSF Servlet? 2
6
framework. 5
Differentiate the JavaScript with jQuery. 2
7
Create an XML document that marks up 2
Grandma White's cookies. A package ofthe nutrition facts for a package of 5
2
package and the following nutritional value per cookies has
serving size of 1 a
serving:
calories, 11 grams of fat, 2 grams of saturated fat, 5 260 calories, 100 fat
210milligrams of sodium, 36 miligrams of cholesterol.
grams total carbohydrates, 2 grams of fiber, 15
of
grams of sugars and 5 grams of protein. Name this document nutrition.xml.
PART- B(2*12=24 marks)
Q. No.
Question
8.a a) What are the object Mark
serialization and deserialization? Assume you have a text3 6
file that contains
Employee's records. Each line contains a record that has the
following data: Emp ID(int), Emp name(string), Emp designation (String) and
Emp salary(int) separated by space characters. Write an application to read this
file and create a new file to save the same data using object
serialization and
deserialization.
date and
8 b) Scket pOgrammi9 To pafnt
tme
OR
8. b a) Write a JavaScript program that readsS afive-letter word from
the user and 3 7
produces all possible three-letter words that can be derived from the letters of
the five-letter word. For example, the three-letter
words produced from the word
"bathe include the commonly used words "ate," "bat," "bet," "tab,"
"hat," "the"
and "tea." Output the results in an HTML5 textarea.
b) Write aJavaScript function that responds to a click
anywhere on the page by
displaying an alert dialog. Display the event name if the user pressed Shift key 5
during the mouse click. Display the element name that triggered the event if the
user pressed Ctrl key during the mouse click.
9.a a) Create aweb page creation using Javascript, Jquery and AJAX. 4|7
b) Write a JSF for. an online shopping market system. Add all the required 5
using a database. The program must also facilitate the creation of a database
and tables, inserting records, deleting records, and updating employees details
in the database.
PART-C(1*12=12 marks)
Q. Question CMartk
No.
10.
a) Write a JavaScript that simulates coin tossing. Let the program toss the coin 6
each time the user clicks the Toss button. Count the number of times each side
of the coin appears. Display the results. The program shoulä call a separate
function flip that takes no arguments and returns false for tails and true for
heads.
6
b) Write ajava program that overload generic method printArray. It takes two
additional integer arguments, lowSubscript and highSubscript. A call to this
method prints only the designated portion of the array. Validate lowSubscript and
highSubscript. If either is out of range, the overloaded printArray method should
throw an InvalidSubscriptException; otherwise, printArray should return the
number of elements printed. Then modify main to exercise both versions of
printArray on arrays integerArray, doubleArray and characterArray. Test all
capabilities of both versions of printArray.