Home >Java >Javagetting Started >What is a reference in java

What is a reference in java

爱喝马黛茶的安东尼
爱喝马黛茶的安东尼Original
2019-11-12 15:32:534418browse

What is a reference in java

Quoted concept

If the type of a variable is a class type rather than a basic type, then the variable Also called a quote. In fact, GC mainly depends on whether the object has a reference pointing to the object. According to the strong and weak relationship of this reference, starting from JDK1.2 version, object references are divided into four levels, so that the program can more flexibly control the life cycle of the object. These four levels, from high to low, are: strong reference, soft reference, weak reference and virtual reference.

php Chinese website, a large number of free Java introductory tutorials, welcome to learn online!

The above is the detailed content of What is a reference in java. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn