Core Java
When you work in an internationalized application java number formats are going to be a head ache. Always use appropriate tools for its respective task. Though you can use a sledge hammer to open a can it is not meant for that. And there is a high possibility that the can might break.
If you are [...]
Overflow and underflow is a condition where you cross the limit of prescribed size for a data type. When overflow or underflow condition is reached, either the program will crash or the underlying implementation of the programming language will have its own way of handing things.
In Java arithmetic operators don’t report overflow and underflow conditions. [...]
Conceptually overloading and overriding is way different. Only the notion about interface name is same in both cases. Other than that, you cannot find a common thing between them.
Overloading is using the same interface but with different inputs and getting different behaviour as output. Slightly confusing right. I hope by end of this article you [...]
Clone (κλών) is a Greek word meaning “branch”, referring to the process whereby a new plant can be created from a twig. In biology it is about copying the DNAs. In real world, if you clone Marilyn Monroe, will you get a copy of her with same beauty and characteristics? No, you will not get! [...]
I do build crazy buildings using my collection of Lego blocks. My 11 months old kid Ben curiously stares at me build it. He always wishes to get hold of it. After I complete the building when I give that to his hand, you know what the first thing he does.
Modify the building blocks. Though [...]
NullPointerException: An attempt was made to use a null reference in a case where an object reference was required.
NullPointerException is more famous to Java programmers, than fashion to Paris. When you start breaking the beurette and Pipette in Java lab, first thing you will get is NullPointerException. In this tutorial lets discuss about, do we [...]
Java Virtual Machine (JVM) is an abstract computing machine. Java Runtime Environment (JRE) is an implementation of the JVM. Java Development Kit (JDK) contains JRE along with various development tools like Java libraries, Java source compilers, Java debuggers, bundling and deployment tools.
JVM becomes an instance of JRE at runtime of a java program. It is [...]
A java exception can be thrown only in the following three scenarios:
(1) An abnormal execution condition was synchronously detected by the Java virtual machine.
- When evaluation of an expression violates the normal semantics (Example: an integer divide by zero)
- An error occurs in loading or linking part of the program
- When limitation on a resource [...]
Type of exceptions in java are checked exceptions and unchecked exceptions. This classification is based on compile-time checking of exceptions. There is also a classification based on runtime in java. It is not widely known! That is synchronous and asynchronous exceptions. First let us see the java checked exceptions and unchecked exceptions.
Checked Exceptions Vs Unchecked [...]
This definition:
Java’s ‘this’ keyword is used to refer the current instance of the method on which it is used.
Following are the ways to use this
1) To specifically denote that the instance variable is used instead of static or local varible.That is,
private String javaFAQ;
void methodName(String javaFAQ) {
this.javaFAQ = javaFAQ;
}
Here this refers to the instance variable. Here [...]