GoConqr has a new look! Let us know what you think.

Mind map

Objects and Classes

Elizabeth Noonan English

Map content

Objects and Classes

  1. what is an Object?

    • Objects are everywhere, can be concrete (things) or abstract (ideas and knowledge)
    • has attributes (fields), that can perform actions (methods)
      • created by using "new" and the keyword of the object
        • once the object is created it can be used to call methods and access fields
    • an object can contain other objects
    • when there is not a value associated it is considered null
  2. What is a Class?

    • To create an object we need the blueprint for that object, a class
    • THE FUNDAMENTAL BUILDING BLOCK OF JAVA!
      • the declaration of class must use the word "Class" followed by the class name and the body must use brackets
        • a class must also have a class definition that is saved in a file that has the same name as the class
    • field
      • also called attribute, are variables that could be primitive data or objects
    • name
    • method
      • actions that a class's object can do
        • the return can be primitive, an object, or void
        • the method main is the entry point to an application
          • needed by only one class
    • Can be represented by a UML class diagram: top is the class name, middle are the class attributes (fields), bottom is the class method
    • EVERY class must have a CONSTRUCTOR
      • used to construct an object
      • usually does not have a return value
      • must have the same name as the class

Information

Description
Mind Map on Objects and Classes, created by Elizabeth Noonan on 10/06/2020.
Views
0
Rating

Feedback

What is it about?

What do you think of the new look?

How do you like it?