0% found this document useful (0 votes)
23 views

Java Practical Index

The document outlines a series of programming assignments covering topics like generics, collections, JSP, Spring Framework, AOP, and RESTful web services. It includes exercises to implement bounded generics, work with lists, sets, and maps, develop web forms with JSP, integrate the Spring container and aspects, perform database operations with JDBC templates, and build REST APIs with Spring Boot. Students are to complete the assignments, which involve creating classes, interfaces, and aspects to demonstrate concepts like dependency injection, exception handling, and database access.

Uploaded by

Rudrakshi Thakur
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
23 views

Java Practical Index

The document outlines a series of programming assignments covering topics like generics, collections, JSP, Spring Framework, AOP, and RESTful web services. It includes exercises to implement bounded generics, work with lists, sets, and maps, develop web forms with JSP, integrate the Spring container and aspects, perform database operations with JDBC templates, and build REST APIs with Spring Boot. Students are to complete the assignments, which involve creating classes, interfaces, and aspects to demonstrate concepts like dependency injection, exception handling, and database access.

Uploaded by

Rudrakshi Thakur
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 3

University of Mumbai

Institute of Distance and Open Learning (IDOL)


PCP CENTER : KJSIT, SION

INDEX
Subject: _______________________________________________________

No. Practical Signature


1 To implement bounded type with generics.
A. Create a class shape with method Area() create circle and
square which extends Class Shape.
Create a generic class BoundedShape that extends
shape. And implement the generics and use area
function accordingly.

B. Create an Interface shape with method Area () create


Circle and Square which implements Class Shape. Create
the generic class Bounded Shape that extends shape.
And implement the generics and use area function
accordingly.

2 To implement List Interface, Set Interface, Map Interface, Lambda


Expression.

A. Create an ArrayList of type Integer, add element into it


traverse the arraylist and print the elements.

B. Create a LinkedList of type string add 5 elements and


traverse the list from both sides.

C. Create an employee class(id, name, salary) create an


Arraylist of type employee, add 5 employees, traverse the
Arraylist and print the elements.
Remove one element and print the list.
D. Write a Java program using Set interface containing list of
items and perform the following operations: a. Add items
in the set.
b. Insert items of one set into another set.
c. Remove items from the set
d. Search the specified item in the set.
E. Create a class Customer( Account_no Integer, Name
String), Create a HashMap of type Customer put
elements, print elements, check if element with account
number 101 is present or not ? What is the value for
Customer 101

F. Write a java program using lambda Expression to calculate


the following
a. Convert Farenheit to Celcsius
b. Convert Kilometers to Miles

3. Web Application development using JSP.

A. To design a form and use of JSP Scripting Element and


JSP Directive. Display Grade of a student by accepting
marks in five subjects.

B. Write a program to design a simple web-based interface


to a currency converter application. The interface should
consist of a title, suitable instructions, and a form for
entering the amount to be converted and an optional
currency rate. Use text fields for entering the amount and
rate.
C. Design loan calculator using JSP which accepts Period of
Time (in years) and Principal Loan Amount. Display the
payment amount for each loan and then list the loan
balance and interest paid for each payment over the term
of the loan for the following time period and interest rate:
a. 1 to 7 year at 5.35%
b. 8 to 15 year at 5.5%
c. 16 to 30 year at 5.75%
D. Write a program using JSP that displays a webpage
consisting of Application form for change of Study
Center which can be filled by any student who wants to
change his/ her study center. Make necessary
assumptions:

4. Implementation of Spring Framework

A. Write a program to print “Hello World” using spring


framework:
d. B. Write a program to demonstrate dependency
injection via setter method

C. Write a program to demonstrate dependency injection


via Constructor.
5. Implementation Of AOP

A. Create class car, bike, airplane, create an aspect engine,


create method drive() in car, ride() in bike, fly in
airplane, the engine aspect has method enginestart()
and enginestop(). When you run the application the
enginestart() method should execute before drive(),
ride() and fly() a enginestop() method should run after
drive(), ride() and fly().

B. Create class car, bike, airplane, create an aspect


engine, create method drive() in car, ride() in bike, fly
in airplane, the engine aspect has method
enginestart() and enginestop(). When you run the
application the enginestart() method should execute
before drive(), ride() and fly() a enginestop() method
should run after drive(), ride() and fly() by using
pointcuts

C. Create a business class multiplier (int a, int b) which


returns product of a and b create an aspect
AdderAfterReturnAspect use After-returning advice
D. Create a voter class with attribute name and age create
an exception check if age is less than 18 throw
exception. Create and aspect illegalVoter with a
method if the voter class throws exception the
illegalVoter aspect method will run.

6 To ement basic database operations using Spring


impl
JDB
C
A Write a program to insert, update and delete records
. from the given table. (Employee Table-Id ,Name, Age)

B Write a program to demonstrate PreparedStatement in


. Spring JdbcTemplate.

C Write a program in Spring JDBC to demonstrate


. ResultSetExtractor Interface.

D Write a program to demonstrate RowMapper interface


. to fetch the records from the database.

7. To implement RESTful Web Services using spring boot.

A. Write a program to demonstrate RESTful Web Services


with spring boot.

You might also like