C++ Programming

C++ Programming


Exception Handling in Java

Posted: 23 May 2013 04:29 AM PDT

The term exception is shorthand for the phrase "exceptional event." Definition : An exception is an event, which occurs during the execution of a program that disrupts the normal flow of the program's instructions.  When an error occurs within a method, the method creates an object and hands it off to the runtime system. The object, called an exception object, contains information about the

What are Abstract Methods and Classes

Posted: 23 May 2013 03:34 AM PDT

Abstract Methods and Classes : An abstract class is a class that is declared abstract—it may or may not include abstract methods. Abstract classes cannot be instantiated, but they can be subclassed. An abstract method is a method that is declared without an implementation (without braces, and followed by a semicolon), like this : abstract void moveTo(double deltaX, double deltaY); If a class

Packages and Interfaces

Posted: 23 May 2013 02:53 AM PDT

Packages Many times when we get a chance to work on a small project, one thing we intend to do is to put all java files into one single directory. It is quick, easy and harmless. However if our small project gets bigger, and the number of files is increasing, putting all these files into the same directory would be a problematic for us. In java we can avoid this sort of problem by using

Wrapper Classes

Posted: 23 May 2013 02:27 AM PDT

Wrapper classes are used to represent primitive values when an Object is required. The wrapper classes are used extensively with Collection classes in the java.util package and with the classes in the java.lang.reflect reflection package. Wrapper classes has the following features :  One for each primitive type: Boolean, Byte, Character, Double, Float, Integer, Long, and Short. Byte, Double,


Post a Comment