2. What is persistence?
Persistence enables beans to save and restore their state. Once you have changed
beans properties you can save the state of the bean and restore that bean at a later
time, property changes are intact. Java beans use java object serialization to support
persistence.
PART-B (15X6=80)
(or)
Platform allows for installation of components and component frameworks that can be
instantiated and activated. It can be concrete or virtual.
Concrete platforms provide direct physical support- that is; implement their services in
hardware.
Platform abstractions or platform shields are another name to virtual platforms. It
emulates a platform on top of another, introducing cost-flexibility trade-off.
Session bean perform business tasks without having a persistent storage mechanism,
such as a database and can use the shared data. There are two types of session beans:
• Stateful session bean
• Stateless session bean
Entity beans are enterprise beans that persist across multiple sessions and multiple
clients. There are two types of entity bean:
• Bean managed persistence
• Container managed persistence
15a) Write a program to create a java bean for adding two numbers.(16)
Create a class which implements any listener interface and write the coding for adding
two numbers.
Create manifest file
Convert into jar file.
(or)
15.b)i. Explain about introspection.(8)
ii. Explain about JAR(8).
Builder tools discover a bean’s features by a process called introspection. This is done
in two ways:
• Design patterns: when naming beans features. Introspection class
examines beans for these design patterns to discover bean features.
(Adhering to specific rules)
Bean information class: implements BeanInfo interface, it lists those bean features that
are exposed to application builder tools. (Explicitly providing information
Explain about JAR(8)
It is a file format based on the popular ZIP file format and is used for aggregating
many files into one.