Java Basic Concepts

Source: Internet
Author: User

Object: The function of the. is the specific entity that exists, with clearly defined characteristics and behavior.

Object-oriented: a way of knowing things, paying attention to the whole cognition of things, the most accord with the natural thinking habit of mankind.

A class is an abstraction of an object that is an instance of a class.

A class is a collection of sets of objects that have the same properties and behavior.

In software systems, we use classes to simulate real-life entities.

Attributes are used to describe the characteristics of an object, the properties of an object are independent from one another, and the properties of an object do not affect the changes of other object properties, which are also called member variables because they are part of an object.

Static variables are created outside the object and are variables shared by all objects, and static variables vary, affecting all objects.

Garbage collection mechanism: Reclaims objects that are not pointed to by the variable.

The difference between a base type and a reference type: 1. In the basic type variable, the specific data is stored. 2. In the reference type variable, the address of the object is stored.

There are three types of reference: class, Array, interface

Null indicates that no object address is stored in the variable, and a null pointer exception is thrown when a method and property call is made to a variable with a value of NULL

Java Basic Concepts

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.