Java Interview Questions and Answers At TCS:
What is a native method?
A native method is a method that is implemented in a language other than Java.
Explain different way of using thread?
A Java thread could be implemented by using Runnable interface or by extending the Thread class. The Runnable is more advantageous, when you are going for multiple inheritance.
What are the two major components of JDBC?
One implementation interface for database manufacturers, the other implementation interface for application and applet writers.
What kind of thread is the Garbage collector thread?
It is a daemon thread.
What are the different ways to handle exceptions?
There are two ways to handle exceptions,
1. By wrapping the desired code in a try block followed by a catch block to catch the exceptions. and
2. List the desired exceptions in the throws clause of the method and let the caller of the method handle those exceptions.
What is nested class?
If all the methods of a inner class is static then it is a nested class.
What is HashMap and Map?
Map is Interface and Hashmap is class that implements that.
What are different types of access modifiers?
public: Any thing declared as public can be accessed from anywhere. private: Any thing declared as private can’t be seen outside of its class. protected: Any thing declared as protected can be accessed by classes in the same package and sub
Tags: Java Interview Questions and Answers At TCS, TCS, Interview Questions and Answers At TCS, JAVA, JAVA Interview Questions, JAVA QA, JAVA Interview Questions and Answers, JAVA Tutorial, JAVA books, JAVA Interview Questions pdf, JAVA experienced, interview questions, JAVA interview questions for experienced, JAVA interview questions for developers,JAVA interview questions for freshers,JAVA interview questions senior level, JAVA Certification Questions, Basic JAVA interview questions, JAVA interview questions 2 3 4 5 6 years experienced, JAVA Real time interview questions, Java Interview Questions and Answers At TCS 2015, Latest Java Questions At TCS Interview.
What is a native method?
A native method is a method that is implemented in a language other than Java.
Explain different way of using thread?
A Java thread could be implemented by using Runnable interface or by extending the Thread class. The Runnable is more advantageous, when you are going for multiple inheritance.
What are the two major components of JDBC?
One implementation interface for database manufacturers, the other implementation interface for application and applet writers.
What kind of thread is the Garbage collector thread?
It is a daemon thread.
What are the different ways to handle exceptions?
There are two ways to handle exceptions,
1. By wrapping the desired code in a try block followed by a catch block to catch the exceptions. and
2. List the desired exceptions in the throws clause of the method and let the caller of the method handle those exceptions.
What is nested class?
If all the methods of a inner class is static then it is a nested class.
What is HashMap and Map?
Map is Interface and Hashmap is class that implements that.
What are different types of access modifiers?
public: Any thing declared as public can be accessed from anywhere. private: Any thing declared as private can’t be seen outside of its class. protected: Any thing declared as protected can be accessed by classes in the same package and sub