The difference between Java member variables and attributes is simple and easy to understand !!!, Java Variables
Example 1: A Student pojo class: public class Student {private String name; private int age; public String getName () {return this. name;} public void setName (String name) {this. name = name;} public int getAge () {return this. age;} public void setAge (int age) {this. age = age ;}} member variables: name and age attributes: the official definition of the property: SUN officially defines the property as "get" or "set Method" after removing the get or set method name, change the first letter of the remaining part to lowercase, that is, the attribute of this class. In this example, attributes refer to name and age. For example, public class student {public String getName () {return "my name is dark_passion! ";}} Member variable: No attribute: name; The above is the difference between java member variables and attributes. Understanding the principle is the best learning!