1
III B.Tech I Semester Regular Examinations, November 2007
OOP THROUGH JAVA
(Instrumentation & Control Engineering)
Time: 3 hours Max Marks: 80
Answer any FIVE Questions
All Questions carry equal marks
⋆⋆⋆⋆⋆
3. Create a 3-level inheritance hierarchy. Each class in the hierarchy should have a
finalize( ) method, and it should properly call the base-class version of finalize( ).
Demonstrate that your hierarchy works properly. [16]
5. (a) When do you use Nested try statements. Explain nested try statements with
the help of an example java program.
(b) Explain nested try statements in the context of method calls with the help of
an example java program. [8+8]
6. (a) Write a java program which draws a dashed line and dotted line using applet.
(b) Write a java program to draw a polygon of eight edges. [10+6]
7. What are various JFC containers? List them according to their functionality. Ex-
plain each of them with examples. [16]
⋆⋆⋆⋆⋆
1 of 1
Code No: R05312203 Set No. 2
III B.Tech I Semester Regular Examinations, November 2007
OOP THROUGH JAVA
(Instrumentation & Control Engineering)
Time: 3 hours Max Marks: 80
Answer any FIVE Questions
All Questions carry equal marks
⋆⋆⋆⋆⋆
4. Create an interface with at least one method, in its own package. Create a class in
a separate package. Add a protected inner class that implements the interface. In
a third package, inherit from your class and, inside a method, return an object of
the protected inner class, upcasting to the interface during the return. [16]
6. What is Event listener? Explain the different Event Listener interfaces supported
by java and their purpose. [16]
7. (a) Explain the application services that can be used in JFC components.
(b) What is double buffering? What purpose does it serve? Explain with a java
skeleton code. 8+8]
⋆⋆⋆⋆⋆
1 of 1
Code No: R05312203 Set No. 3
III B.Tech I Semester Regular Examinations, November 2007
OOP THROUGH JAVA
(Instrumentation & Control Engineering)
Time: 3 hours Max Marks: 80
Answer any FIVE Questions
All Questions carry equal marks
⋆⋆⋆⋆⋆
1. (a) Describe the genesis of java. Also write brief overview of java.
(b) Write a program to convert the given temperature in Fahrenheit to Celsius us-
ing the following conversion formula C = (F - 32)/1.8 And display the values
in a tabular form. [8+8]
4. Write an interface called shape with necessary methods.Derive classes circle, rec-
tangle, triangle, cone, sphere and cube with appropriate constructors and methods
for area, volume also setting & displaying. [16]
(a) ComponentEvent
(b) ContainerEvent
(c) FocusEvent. [6+5+5]
⋆⋆⋆⋆⋆
1 of 1
Code No: R05312203 Set No. 4
III B.Tech I Semester Regular Examinations, November 2007
OOP THROUGH JAVA
(Instrumentation & Control Engineering)
Time: 3 hours Max Marks: 80
Answer any FIVE Questions
All Questions carry equal marks
⋆⋆⋆⋆⋆
⋆⋆⋆⋆⋆
1 of 1