Skip to main content
Logo image

Java, Java, Java: Object-Oriented Problem Solving, 2022E

Section 0.9 Chapter Summary

Subsection 0.9.1 Technical Terms

action (behavior) argument attribute
class class inheritance class hierarchy
class method class variable compiler
computer program constructor high-level language
instance instance method instance variable
interpreter method message
object object code object oriented
result source code subclass
superclass Unified Modeling Language (UML) variable

Subsection 0.9.2 Important Points

  • A computer system generally consists of input/output devices, primary and secondary memory, and a central processing unit. A computer can only run programs in its own machine language, which is based on the binary code. Special programs known as compilers and interpreters translate source code programs written in a high-level language, such as Java, into machine language object code programs. Application software refers to programs designed to provide a particular task or service; systems software assists the user in using application software.
  • The client/server model is a form of distributed computing in which part of the software for a task is stored on a server and part on client computers.
  • HyperText Markup Language (HTML) is the language used to encode WWW documents.
  • A Java program is a set of interacting objects. This is the basic metaphor of object-oriented programming.
  • An object in a Java program encapsulates the program’s attributes (or variables) and actions (or methods). A variable is a named memory location where data of appropriate type can be stored. A method is a named section of code that can be called (or invoked) when needed.
  • An object’s methods are used to pass messages to it.
  • A class is an abstract template that defines the characteristics and behaviors of all objects of a certain type.
  • An object is an instance of a class. An object has instance methods and instance variables. A class method (or class variable) is a method (or variable) that is associated with the class itself, not with its instances.
  • A constructor is a special method that is used to construct objects.
  • Java classes are organized into a class hierarchy, with the Object class at the top of the hierarchy. For a given class, classes that occur below it in the hierarchy are called its subclasses, while classes that occur above it are called its superclasses.
  • Classes inherit attributes and methods from their superclasses. This is known as class inheritance.
  • The main principles of the object-oriented programming approach are as follows:
    • Divide and Conquer: Successful problem solving involves breaking a complex problem into objects.
    • Encapsulation and Modularity: Each object should be assigned a clear role.
    • Public Interface: Each object should present a clear public interface that determines how other objects will use it.
    • Information Hiding: Each object should shield its users from unnecessary details of how it performs its role.
    • Generality: Objects should be designed to be as general as possible.
    • Extensibility: Objects should be designed so that their functionality can be extended to carry out more specialized tasks.
    • Abstraction is the ability to group a large quantity of information into a single chunk so it can be managed as a single entity.
You have attempted of activities on this page.