Classes and Objects
The course is part of this learning path
This course looks at Object-Oriented programming in Java and shows how classes are designed and constructed, and how objects are created from them. Then, we'll complete three projects: creating a bank account class, an ice cream class, and a circle class, as well as tests to make sure that they work in order to reinforce what you've learned.
- Beginner coders or anyone new to Java
- Experienced Java programmers who want to maintain their Java knowledge
- Developers looking to upskill for a project or career change
- College students and anyone else studying Java
This is a beginner-level course and can be taken by anyone with an interest in learning about Java.
In this section, we've taken our first steps to understanding the power that object-oriented programming offers us. We've learned about the three primary principles of object-oriented programming: encapsulation, inheritance, and polymorphism. And we have focused primarily on encapsulation in this section, that is the binding of data in the form of fields and behaviors, in the form of methods, into distinct entities, objects, and that they have blueprints from which they're created called classes. We learned about what models are and specifically about UML class diagrams, and how they can help us understand what our classes might need in order to accomplish its goals. We worked on House, Rectangle, and Book classes together to get a feel for creating our own user defined classes. Then we rounded out the section with three awesome projects where we created BankAccount, IceCream, and Circle classes
to further test out our newfound skills. As you can see, you can represent all sorts of things with classes. We will be using classes in various ways throughout the remainder of the course. Sometimes, we'll be using classes and objects that have been created for us, and sometimes we'll be creating our own classes. I'm excited for the next section in which we will discuss how to work with file input and output, also called file I/O for short. With file I/O, we'll be able to save and load persistent data, that is data that's been saved to secondary storage devices like hard drives and flash drives. Let's get going with the next section.
John has a Ph.D. in Computer Science and is a professional software engineer and consultant, as well as a computer science university professor and department chair.