Object Core

Exception Handler

Here we are going to start a exception handler of handling the occurance of error.

To start the exception we must know a few info about the try{} catch() and finally{}.

Try{}
This try helps is to try any operation and if there appears any error then it directly goes to the catch() method to check either the error matches with the exception defined at catch(). If no any catch is found then it directly goes to finally{} method for end of try{} method.

Read More »Exception Handler

Enum (eration) in Java

Here you can see the structure of Enum class in java. This class have their own rules and regulation.In this class there is no use of public except in the method value and class access because it doesn’t give any access to client. Some changable user-defined are written in italics.

For enum define , Just use below syntax

Read More »Enum (eration) in Java

Frame Height in Applet

Actually the the height we defined for JFrame may differ as what we assume . In windows JFrame uses its height including it’s title bar and the bottom border of window frame.It can be illustrated below :
Let’s we code the JFrame size.

In this code we can see that we defined a JFrame size to 100px width and 100px height. But actually some programmer feels problem on the height of the windows size , even we had declare the size of the JFrame to 100. The JFrame height includes the title bar and it’s bottom liner height.

Read More »Frame Height in Applet