What Is Reflection?
Reflection allows programmatic access to information about the fields, methods and constructors of loaded classes, and the use reflected fields, methods, and constructors to operate on their underlying counterparts on objects, within security restrictions.
What Is The Base Class For Error And Exception?
Throwable
What Is The Implementation Of Destroy Method In Java.. Is It Native Or Java Code?
This method is not implemented.
What Are The Approaches That You Will Follow For Making A Program Very Efficient?
By avoiding too much of static methods avoiding the excessive and unnecessary use of synchronized methods Selection of related classes based on the application (meaning synchronized classes for multiuser and non-synchronized classes for single user) Usage of appropriate design patterns Using cache methodologies for remote invocations Avoiding creation of variables within a loop and lot more.
What Is A Databasemetadata?
Comprehensive information about the database as a whole.
What Is Locale?
A Locale object represents a specific geographical, political, or cultural region.
How Will You Load A Specific Locale?
Using ResourceBundle.getBundle(…);
What Is Jit And Its Use?
Really, just a very fast compiler… In this incarnation, pretty much a one-pass compiler — no offline computations. So you can’t look at the whole method, rank the expressions according to which ones are re-used the most, and then generate code. In theory terms, it’s an on-line problem.
Is Jvm A Compiler Or An Interpreter?
Interpreter
What Is The Purpose Of Assert Keyword Used In Jdk1.4.x?
In order to validate certain expressions. It effectively replaces the if block and automatically throws the AssertionError on failure. This keyword should be used for the critical arguments. Meaning, without that the method does nothing.
How Will You Get The Platform Dependent Values Like Line Separator, Path Separator, Etc., ?
Using Sytem.getProperty(…) (line.separator, path.separator, …)
Is "abc" A Primitive Value?
The String literal “abc” is not a primitive value. It is a String object.
What Is Singleton?
It is one of the design pattern. This falls in the creational pattern of the design pattern. There will be only one instance for that entire JVM. You can achieve this by having the private constructor in the class. For eg., public class Singleton { private static final Singleton s = new Singleton(); private Singleton() { } public static Singleton getInstance() { return s; } // all non static methods … }
Can You Instantiate The Math Class?
You can’t instantiate the math class. All the methods in this class are static. And the constructor is not public.
What Are The Methods In Object?
clone, equals, wait, finalize, getClass, hashCode, notify, notifyAll, toString.
What Is Aggregation?
It is a special type of composition. If you expose all the methods of a composite class and route the method call to the composite method through its reference, then it is called aggregation.
What Is Composition?
Holding the reference of the other class within some other class is known as composition.
What Is Inner Class?
If the methods of the inner class can only be accessed via the instance of the inner class, then it is called inner class.
What Is Nested Class?
If all the methods of a inner class is static then it is a nested class.
What Is The Major Difference Between Linkedlist And Arraylist?
LinkedList are meant for sequential accessing. ArrayList are meant for random accessing.
What Is The Significance Of Listiterator?
You can iterate back and forth.
What Is The Final Keyword Denotes?
final keyword denotes that it is the final implementation for that method or variable or class. You can’t override that method/variable/class any more.
What Is Skeleton And Stub? What Is The Purpose Of Those?
Stub is a client side representation of the server, which takes care of communicating with the remote server. Skeleton is the server side representation. But that is no more in use… it is deprecated long before in JDK.
Why Does It Take So Much Time To Access An Applet Having Swing Components The First Time?
Because behind every swing component are many Java objects and resources. This takes time to create them in memory. JDK 1.3 from Sun has some improvements which may lead to faster execution of Swing applications.
What Is The Difference Between Instanceof And Isinstance?
instanceof is used to check to see if an object can be cast into a specified type without throwing a cast class exception. isInstance() Determines if the specified Object is assignment-compatible with the object represented by this Class. This method is the dynamic equivalent of the Java language instanceof operator. The method returns true if the specified Object argument is non-null and can be cast to the reference type represented by this Class object without raising a ClassCastException. It returns false otherwise.
What Does The "final" Keyword Mean In Front Of A Variable? A Method? A Class?
FINAL for a variable: value is constant. FINAL for a method: cannot be overridden. FINAL for a class: cannot be derived.
Reflection allows programmatic access to information about the fields, methods and constructors of loaded classes, and the use reflected fields, methods, and constructors to operate on their underlying counterparts on objects, within security restrictions.
What Is The Base Class For Error And Exception?
Throwable
What Is The Implementation Of Destroy Method In Java.. Is It Native Or Java Code?
This method is not implemented.
What Are The Approaches That You Will Follow For Making A Program Very Efficient?
By avoiding too much of static methods avoiding the excessive and unnecessary use of synchronized methods Selection of related classes based on the application (meaning synchronized classes for multiuser and non-synchronized classes for single user) Usage of appropriate design patterns Using cache methodologies for remote invocations Avoiding creation of variables within a loop and lot more.
What Is A Databasemetadata?
Comprehensive information about the database as a whole.
What Is Locale?
A Locale object represents a specific geographical, political, or cultural region.
How Will You Load A Specific Locale?
Using ResourceBundle.getBundle(…);
Luxoft Most Frequently Asked Core Java Interview Questions Answers |
What Is Jit And Its Use?
Really, just a very fast compiler… In this incarnation, pretty much a one-pass compiler — no offline computations. So you can’t look at the whole method, rank the expressions according to which ones are re-used the most, and then generate code. In theory terms, it’s an on-line problem.
Is Jvm A Compiler Or An Interpreter?
Interpreter
What Is The Purpose Of Assert Keyword Used In Jdk1.4.x?
In order to validate certain expressions. It effectively replaces the if block and automatically throws the AssertionError on failure. This keyword should be used for the critical arguments. Meaning, without that the method does nothing.
How Will You Get The Platform Dependent Values Like Line Separator, Path Separator, Etc., ?
Using Sytem.getProperty(…) (line.separator, path.separator, …)
Is "abc" A Primitive Value?
The String literal “abc” is not a primitive value. It is a String object.
What Is Singleton?
It is one of the design pattern. This falls in the creational pattern of the design pattern. There will be only one instance for that entire JVM. You can achieve this by having the private constructor in the class. For eg., public class Singleton { private static final Singleton s = new Singleton(); private Singleton() { } public static Singleton getInstance() { return s; } // all non static methods … }
Can You Instantiate The Math Class?
You can’t instantiate the math class. All the methods in this class are static. And the constructor is not public.
What Are The Methods In Object?
clone, equals, wait, finalize, getClass, hashCode, notify, notifyAll, toString.
What Is Aggregation?
It is a special type of composition. If you expose all the methods of a composite class and route the method call to the composite method through its reference, then it is called aggregation.
What Is Composition?
Holding the reference of the other class within some other class is known as composition.
What Is Inner Class?
If the methods of the inner class can only be accessed via the instance of the inner class, then it is called inner class.
What Is Nested Class?
If all the methods of a inner class is static then it is a nested class.
What Is The Major Difference Between Linkedlist And Arraylist?
LinkedList are meant for sequential accessing. ArrayList are meant for random accessing.
What Is The Significance Of Listiterator?
You can iterate back and forth.
What Is The Final Keyword Denotes?
final keyword denotes that it is the final implementation for that method or variable or class. You can’t override that method/variable/class any more.
What Is Skeleton And Stub? What Is The Purpose Of Those?
Stub is a client side representation of the server, which takes care of communicating with the remote server. Skeleton is the server side representation. But that is no more in use… it is deprecated long before in JDK.
Why Does It Take So Much Time To Access An Applet Having Swing Components The First Time?
Because behind every swing component are many Java objects and resources. This takes time to create them in memory. JDK 1.3 from Sun has some improvements which may lead to faster execution of Swing applications.
What Is The Difference Between Instanceof And Isinstance?
instanceof is used to check to see if an object can be cast into a specified type without throwing a cast class exception. isInstance() Determines if the specified Object is assignment-compatible with the object represented by this Class. This method is the dynamic equivalent of the Java language instanceof operator. The method returns true if the specified Object argument is non-null and can be cast to the reference type represented by this Class object without raising a ClassCastException. It returns false otherwise.
What Does The "final" Keyword Mean In Front Of A Variable? A Method? A Class?
FINAL for a variable: value is constant. FINAL for a method: cannot be overridden. FINAL for a class: cannot be derived.
Post a Comment