Java Interview Questions -46

Java Interview Questions -46 1. What is CLASSPATH variable? What is default classpath? CLASSPATH is an environment variable that communicates JVM and other java applications for finding the java language class libraries, including the developer’s class library. 2. Explain how to convert any Java Object into byte array. Create an object of ByteArrayOutputStream class. ByteArrayOutputStream […]

Java Interview Questions -44

Java Interview Questions -44 1.Why should we go for interservlet communication? Servlets running together in the same server communicate with each other in several ways. The three major reasons to use interservlet communication are: a) Direct servlet manipulation – allows to gain access to the other currently loaded servlets and perform certain tasks (through the […]

Java Interview Questions -42

Java Interview Questions -42 1.What is an Aspect? An aspect is the cross-cutting functionality that you are implementing. It is the aspect of your application you are modularizing. An example of an aspect is logging. Logging is something that is required throughout an application. However, because applications tend to be broken down into layers based […]

Java Interview Questions -40

Java Interview Questions -40 1.What is session tracking and how do you track a user session in servlets? Session tracking is a mechanism that servlets use to maintain state about a series requests from the same user across some period of time. The methods used for session tracking are: a) User Authentication – occurs when […]

Java Interview Questions -39

Java Interview Questions -39 1.Does Hibernate Session Object has any cache associated with it by default ? Yes, first-level caching is a mandatory requirement for Hibernate Session Object. 2.Is there any cache associated with Hibernate SessionFactory Object? Yes, there is an optional second-level cache with Hibernate SessionFactory object. 3.Can a single Hibernate Session object be […]

Java Interview Questions and Answers

Java Interview Questions and Answers Java Interview Questions -1 Java Interview Questions -2 Java Interview Questions -3 Java Interview Questions -4 Java Interview Questions -5 Java Interview Questions -6 Java Interview Questions -7 Java Interview Questions -8 Java Interview Questions -9 Java Interview Questions -10 Java Interview Questions -11 Java Interview Questions -12 Java Interview […]

Java Interview Questions -38

Java Interview Questions -38 1.What is IOC (or Dependency Injection)? The basic concept of the Inversion of Control pattern (also known as dependency injection) is that you do not create your objects but describe how they should be created. You don’t directly connect your components and services together in code but describe which services are […]

Java Interview Questions -37

Java Interview Questions -37 1.Why is Servlet so popular? Because servlets are platform-independent Java classes that are compiled to platform-neutral byte code that can be loaded dynamically into and run by a Java technology-enabled Web server. 2.What is servlet container? The servlet container is a part of a Web server or application server that provides […]

Java Interview Questions -36

Java Interview Questions -36 1.What is ActionMapping in struts? Action mapping defines the flow of one request. The possible sequence is User -> request -> Form -> Validation -> Business Code -> Forward -> JSP -> response -> User. The components involved are Action classes, Forms and JSP. 2.What are the advantages of having multiple […]

Java Interview Questions -35

Java Interview Questions -35 1.What is JBoss cache in short? JBoss cache is a product. Frequently accessed Java objects are cached by utilzing JBoss cache to improve the performance of e-business applications. JBoss decreases the network traffic and increases the scalability of applications by eliminating unnecessary database acces.Fully transactional features and highly configurable set of […]