java notes

java  notes EDUCATIONAL NOTES

HI FRIENDS THIS THE COMMUNITY FOR THE STUDENTS WHO ARE STUDYING IN
"BCA" "B.SC IT" "B.SC COMMUTER SCIENCE" IT WILL DEFIANTLY HELPS YOU IN STUDY

exceptions handling
06/08/2011

exceptions handling

17/07/2011

Please write a java code to print your name,and ya the code should not contain semicolon(;)

14/07/2011

Constructor

14/07/2011

Invoking an Object’s Method

14/07/2011

Using a Reference to an Object
• Once the object has been created (with the
new operator), the variable str1 refers to
that object.
• That object has several methods, one of
them is the length() method.
• A String object's length() method counts the
characters in the string, and returns that
amount

14/07/2011

Objects
• A variable that can refer to an object does not
always have an object to refer to.
• In our program the variable str1 refers to an object
only after the new operator creates one.
• Before the new operator did its work, str1 was a
"place holder" that did not actually refer to any
object.
• After the new operator creates the object, str1 is
used to refer to the object.

14/07/2011

Class and Object
• A class is merely a template for one or more
objects. It describes an object’s behavior
and state.
• It does not create any objects.
• When a programmer wants to create an
object the new operator is used with the
name of the class.
• Creating an object is called instantiation.

14/07/2011

Objects
• The methods do not run in any order. For an
application, the first method to run is the
method named main. There should be only
one method named main in an application.
• In a small application, main might do by
itself all the computation that needs to be
done. In a larger application, main will
create objects and use their methods.

14/07/2011

Objects
• In object-oriented programming,
programmers use a programming language
(such as Java) to describe the program as
various objects. When the program is run, the
object are created, and they start "doing
things" by running their methods

14/07/2011

Class
• A group of objects with similar properties and
behaviors is described by a class.
• Class is a pattern for an object.
• A class contains fields and methods that define
the behavior of the object.
• A class is a description of a kind of object.
• A programmer may define a class using Java, or
may use predefined classes that come in class
libraries such as the JDK.

14/07/2011

Objects
• Many programs are written to model
problems of the real world.
• It is convenient to have "software objects"
that are similar to "real world objects." This
makes the program and its computation
easier to think about.
• Object-oriented programming solve a
problem by creating objects that solve the
problem.

14/07/2011

Objected-oriented Programming

Address

Silvassa
396230

Website

Alerts

Be the first to know and let us send you an email when java notes posts news and promotions. Your email address will not be used for any other purpose, and you can unsubscribe at any time.

Contact The Business

Send a message to java notes:

Share