Posts

Showing posts from April, 2017

Java Interview Question

1.Can we access instance variables within static methods ? 2.Difference between shallow cloning and deep cloning of objects? 3.What happens if one of the members in a class does not implement Serializable interface?   4.How garbage collector knows that the object is not in use and needs to be removed? 5.What is daemon thread?    6.What is the difference between a REST web service and a SOAP web service?   7. Difference between @Secured vs @RolesAllowed vs @PreAuthorize in Spring Security? 8.Explain the RowCallbackHandler in Spring?   9.What are the differences between forward() and sendRedirect() methods in Servlet?   10.How to execute stored procedure in hibernate 11.Write a Java program to remove duplicate elements from an arraylist without using collections (without using set) 12.Write a program to convert a string array to arraylist? 13.Write a program for Bubble Sort in java. 14.Write a program to g...