+ 1

Explain the function of get and set feature in java

17th Mar 2018, 12:38 PM
Devansh Gupta
Devansh Gupta - avatar
3 Answers
0
Getters are used to access/get private variable. Setters are used to set private variable to value.
17th Mar 2018, 1:26 PM
Sad
Sad - avatar
0
an example if you don't mind
17th Mar 2018, 2:09 PM
Devansh Gupta
Devansh Gupta - avatar