Java Tutorial 19 – Accessor and Mutator Methods (Setters and Getters)

///Java Tutorial 19 – Accessor and Mutator Methods (Setters and Getters)

Java Tutorial 19 – Accessor and Mutator Methods (Setters and Getters)

FavoriteLoadingAdd to favorites

In this tutorial, we talk about accessor and mutator methods (also known as setter and getter methods), which can be used to access data that has been encapsulated within a class.

Java468x60

TechnicalCafe Blog:

TechnicalCafe Twitter:

Jamie’s Twitter:

source

By |2020-12-06T10:56:43+00:00December 6th, 2020|Java Video Tutorials|23 Comments

23 Comments

  1. Daniel Viglietti December 6, 2020 at 10:56 am - Reply

    Thanks for being the only person who could make this as simple as possible.

  2. Aarya Deshpande December 6, 2020 at 10:56 am - Reply

    You literally explained the concepts to the point where I could teach someone else.
    Literally, I never understood anything about this before. This video has really taught me that when it comes to programming, actually coding yourself, questioning, then teaching is the best explanatory process (teacher). I often don't get a word my teacher or my textbook says when explaining such concepts in Java because they have no meaning until you have the picture (engaging yourself). Videos like these are lifesavers! (This was like Khan Academy, but Computer Science) Thank you!! Keep up the videos!!

  3. Hexadecimal December 6, 2020 at 10:56 am - Reply

    awh you didnt write the setter or getter method for the string and include and validate it……

  4. Jovany Hernandez December 6, 2020 at 10:56 am - Reply

    Please become a professor at ksu🙏

  5. Study Room December 6, 2020 at 10:56 am - Reply

    Thanks for your give information about asesor method and mutator method

  6. Gibran Ahmed December 6, 2020 at 10:56 am - Reply

    To be honest, I am new to Java. your tutorials are so helpful and easy to follow. I am currently follow series of your tutorials and they are amazing.

  7. John Harris December 6, 2020 at 10:56 am - Reply

    Thanks this cleared everything up

  8. Tia C December 6, 2020 at 10:56 am - Reply

    super informative video thank you!

  9. Saidm Shah December 6, 2020 at 10:56 am - Reply

    Thanks, it helped me a lot and got me out of a big confusion.

  10. Sora December 6, 2020 at 10:56 am - Reply

    You explained in less than 10 minutes what my teacher couldn't in an entire period. Thank you so much!

  11. charlie Gong December 6, 2020 at 10:56 am - Reply

    You made it so clear!! Just one question, I saw some of mutators start with public void set instead of void set, why is that?

  12. Young Pedro December 6, 2020 at 10:56 am - Reply

    Hey guys its scarce here

  13. Zachary Chapman December 6, 2020 at 10:56 am - Reply

    Helpful video! Thanks!

  14. Focus Addiction December 6, 2020 at 10:56 am - Reply

    I still don't get the point of doing this instead of changing the variable directly without the acessors. Both will change the variables, won't they? What's the point? I know there is one, but i can't understand it.

  15. Michael Gonzalez December 6, 2020 at 10:56 am - Reply

    how would the balance var get updated?

  16. NatMesh December 6, 2020 at 10:56 am - Reply

    Your the man with the master plan, this really helped clearly up this concept for me. Thanks you!

  17. Usman Ali December 6, 2020 at 10:56 am - Reply

    nice

  18. Christine Slotkoff December 6, 2020 at 10:56 am - Reply

    You should teach my programming class! I can't believe I actually understand my assignment now. thank you!!

  19. YoMommaStank December 6, 2020 at 10:56 am - Reply

    ayy thanks for breaking it down. I understood the get, but didn't really understood the mutator. I didn't know what the output was supposed to be. Now I get the concept of my assignment.

  20. Alain Karam December 6, 2020 at 10:56 am - Reply

    you sound like scarce

  21. Christopher Myers December 6, 2020 at 10:56 am - Reply

    why does it return 250.0 instead of 250.00?

  22. NivKotz December 6, 2020 at 10:56 am - Reply

    Just want to say thank you so much for all the videos you really helped me a lot!!! 🙂

  23. James Whyte December 6, 2020 at 10:56 am - Reply

    Incredibly well demonstrated! I like how you get straight to the point right off the bat. This is like visual gold. Bar none the best lesson I've seen on the topic.

    Bravo!!

Leave A Comment

*