————————————————————————————————————————————————————————
Attribute name/Type | Getter Method | Setter method
———————————— | —————————————————— | ——————————————————————————
xcoordinate/double | Public Double getxcoordinate () | public void Setxcoordinate (Double newvalue)
———————————— | —————————————————— | ——————————————————————————
xcoordinate/double | Public double getxcoordinate () |public void Setxcoordinate (double newvalue)
———————————— | —————————————————— | ——————————————————————————
Xcoordinate/double |public Double getxcoordinate () | public void Setxcoordinate (Double newvalue)
———————————— | —————————————————— | ——————————————————————————
xcoordinate/double | not allowed | Not allowed
———————————— | —————————————————— | ——————————————————————————
The first and fourth cases need to be noted. You don't need to think about this when using the IDE, but you should be aware of the handwriting code.
JavaBean Naming conventions