Ενότητα 1: Εισαγωγή στην Αντικειμενοστρέφεια
ΕΠΛ133: Σύνοψη και Προσανατολισμός
Learning Objectives
Readings
Notes
Learning Objectives:
Understand how to study and succeed in EPL133.
Ανασκόπηση Στοιχείων Προγραμματισμού Java
Learning Objectives
Learning Objectives:
Refresh Java Programming and execution skills.
Understand and explain the concept of Java Classes, recursion, and explore the concepts of class
design, object state and performance through the example of a Fibonacci implementation in Java.
Practice with the concepts of compilation, interpretation, the role of JVM, and bytecodes.
Εισαγωγή στην Υπολογιστική Σκέψη
Learning Objectives
Readings
Notes
Learning Objectives:
Understand computational thinking and be able to model and solve problems computationally.
Understand the concepts of problem formulation, problem solving,
and state representation in solving computational problems.
Understand the concept of well-defined problems and apply it to translate abstract problem descriptions
to computational problems.
Readings:
Review Chapters 1-3. "Absolute Java" , Walter Savitch.
Η Πλατφόρμα της Java (Java platform).
Learning Objectives
Readings
Video: History & Key Concepts
Video: Java Platform Overview
Learning Objectives: Understand and be able to explain and use:
Key programming terminology: compilation, interpretation, debugging, virtual machine, source code,
object code, assembly language, intermediate languages.
Basic concepts of object-oriented programming.
The history of Object-oriented Programming.
The main aspects of the Java programming language.
The Java platform.
Interpretation vs. Compilation of computer programs.
Τhe Java Virtual Machine (JVM) and Bytecodes.
The concept of Multi-threading.
The lifecycle of a Java program.
Η Έννοια της «Αφαίρεσης» στον Προγραμματισμό (Abstraction)
Learning Objectives
Readings
Learning Objectives: Understand, identify and be able to employ key concepts
of abstraction, such as hierarchy and data abstraction. Understand how abstraction is used
to manage complexity. Understand the concepts of objects and classes. Understand the notions
of object properties (fields), object behaviors (methods), object id (handle).
Readings: Chapter 4.1 "Absolute Java" , Walter Savitch.
Τεχνοτροπία Προγραμματισμού (Programming style)
Learning Objectives
Readings
Notes
Programming Conventions
Learning Objectives:
Overview of naming conventions for packages, classes, variables.
Σχεδιασμός Κλάσεων
Learning Objectives
Readings
Notes
Video: Elements of Java Classes
Video: OOP Abstractions in Java
Learning Objectives: Understand, identify and be able to:
Design Java classes, create Java objects, invoke methods and make proper use of
method parameters, arguments, and object handles.
Explain the concept of call-by-value vs. call-by-reference argument passing.
Use the parameter "this".
Readings: Chapter 4.1 "Absolute Java" , Walter Savitch.
Unified Modeling Language (UML): Διαγράμματα Κλάσεων και Συσχετίσεων
Learning Objectives
Readings
Notes
Learning outcome:
Understand, explain, and apply the design of programs using pseudocode and UML.
Understand, explain, and apply UML class diagrams and UML associations between classes.
Readings:
Chapter 12, Absolute Java, Walter Savitch.
Object-Oriented Design and Patterns. Cay Horstmann, Wiley, 2006.
Chapter 3, The Practice of Programming. Kernighan and Pike, Addison Wesley, 1999.
Αντικειμενοστρεφής Σχεδιασμός: Κλάσεις, Υπευθυνότητες, Συνεργάτες (CRC)
Learning Objectives
Readings
Video: OO Design Methodology
Learning Objectives:
Review key elements of the object-oriented design.
Become familiar and put to practice the O.O. design methodology.
Use the Class-Responsibility-Collaborators (CRC) cards to design your classes.
Readings:
Chapter 12. Absolute Java. Walter Savitch.
Chapter 2. Object-Oriented Design and Patterns. Cay Horstmann, Wiley, 2006.
Ενότητα 2: Διαχείριση Μνήμης (Memory Management) και Αναλλοίωτοι Περιορισμοί (Invariants)
Κλάσεις και Κατασκευή Αντικειμένων (Object Construction)
Learning Objectives
Readings
Notes
Video: Initializers and Constructors
Learning Objectives:
Understand the concepts of information hiding and encapsulation in Java.
Private and public class members.
Accessor and Mutator Methods.
Understand Java object construction and initialization.
Method and constructor overloading.
Readings:
Chapter 4.2, 4.3, 4.4. "Absolute Java" , Walter Savitch.
Review of recursion. Chapter 11. "Absolute Java" ,
Walter Savitch.
Διαχείριση Μνήμης (Memory Management)
Learning Objectives
Readings
Notes 7/2
Notes 10/2
Memory Mgt Intro.
Java Memory Mgt
Learning Objectives: Understand, explain and use the concepts of:
Java object construction and initialization.
Method and constructor overloading.
Memory Management.
Memory allocation.
The organization of virtual memory, the concepts of stack, heap and static memory.
Activation records (stack frames) and their role in maintaining method invocation semantics.
Heap-space allocation for storing Java objects.
Review of memory management in the presence of method calls: stack, stack-frames (activation records), heap.
Understand the concept of garbage collection. Garbage collection in Java
and related methods. Algorithms for garbage collection.
Static memory, static variables (class variables) and static methods (class methods).
Review examples of static variables and methods and be able to explain and implement the concept.
Understand and explain garbage collection and garbage collection mechanisms in Java.
Understanding static and dynamic string concatenation in Java.
Static Initialization Block.
Περιβάλλουσες Κλάσεις (Wrapper Classes)
Learning Objectives
Readings
Notes
Wrapper Classes
Class Parameters
Object Equality
Learning Objectives:
Understand and be able to use wrapper classes instead of primitive types.
Revisit the call-by-value approach for passing arguments to method calls in the case of class parameters.
Understand and explain how to control for the equality of objects.
Readings:
Chapter 5. "Absolute Java" , Walter Savitch.
Review recursion and stacks for recursion. Chapter 11. "Absolute Java" , Walter Savitch.
Αναλλοίωτοι Περιορισμοί (Invariants)
Learning Objectives
Readings
Notes 14/2
Notes 17/2
Learning Objectives:
Understand the concept of invariants, class invariants and their implications for class design.
Apply class invariants in constructors and methods. Expand on encapsulation and information
hiding through copy constructors.
Understand the concepts of privacy leakage, mutable and immutable classes, and how to address privace leakage.
Readings: Chapter 5. "Absolute Java" , Walter Savitch.
Ενότητα 3: Επαναχρησιμοποίηση Κώδικα (Code reuse) και Κληρονομικότητα (Inheritance)
Κληρονομικότητα (Inheritance)
Learning Objectives
Readings
Notes
Learning objectives:
Understand and apply the concepts of class re-use through composition and
inheritance.
Understand and apply the concept inheritance as an abstraction and Java programming technique.
Develop an understanding of the relation between inheritance and class hierarchy.
Readings: Chapter 7. Absolute Java Walter Savitch.
Επαναχρησιμοποίηση Κώδικα και Βιβλιοθήκες (Code reuse and Packages in Java)
Learning Objectives
Readings
Notes
Java Packages
Name Visibility
Learning Objectives:
Understand and explain how to create and re-use Java libraries (packages).
Understand, explain, and use the Linux filesystem and environment variables.
Understanding the role of CLASSPATH and how to set it up.
Readings: Chapter 5.4 Absolute Java Walter Savitch.
Κληρονομικότητα και Κατασκευή Αντικειμένων (Inheritance and Object Construction)
Learning Objectives
Readings
Notes
Encapsulation and Inheritance
Learning Objectives:
Understand and explain how object construction works in the case of inherited classes.
Be familiar with final classes and final class members.
Understand, explain, and apply the concepts of Composition vs Inheritance.
Understand, explain, and apply the concept of Design Patterns and Delegation.
Readings: Chapter 7. Absolute Java
Walter Savitch.
Κληρονομικότητα και Προγραμματιστικές Τεχνικές (Programming Techniques and Inheritance)
Learning Objectives
Readings
Notes
Learning outcome:
Text processing and tokens.
Markov Chain algorithm for text generation.
Review of examples with inheritance: processing strings with StringTokenizer.
The "Object" class.
Class introspection with getClass() and instanceOf.
Readings:
Chapter 4.4 (StringTokenizer class) Absolute Java Walter Savitch.
Chapter 7. Absolute Java Walter Savitch.
StringTokenizer API.
Αναβάθμιση Τύπου (Upcasting)
Learning objectives
Readings
Notes
Learning objectives:
Understand, recognize and apply of upcasting and its implications.
Review of examples with inheritance and upcasting.
Understand and explain how encapsulation specifiers work with inheritance and
the differences between access specifiers: private, protected, public.
Readings: Chapter 7. Absolute Java
Walter Savitch.
Ενότητα 4: Πολυμορφισμός (Polymorphism)
Εισαγωγή στον Πολυμορφισμό
Learning objectives
Readings
Notes
Learning objectives:
Understand and recognize the concept of Polymorphism.
Understand and explain the concept of binding.
Readings: Chapter 8. Absolute Java Walter Savitch.
Πολυμορφικές κλήσεις μεθόδων
Learning Objectives
Readings
Notes
Learning Objectives:
Understand, explain and apply the concept of polymorphic method calls.
Understand, apply and explain the concept of binding, static and dynamic.
Understand and explain the concepts of compile-time vs. execution-time.
Understand and apply how Polymorphism works with Static methods: Overriding vs. Hiding.
Explore, explain and apply the relation between polymorphism and instance variables.
Understand, explain and apply how polymorphism works inside constructors.
Understand, explain and apply the concept of downcasting.
Understand, explain and apply the clone method.
Understand, explain and apply alternative ways for polymorphic behavior through the change-state design
pattern.
Readings: Chapter 8. Absolute Java, Walter Savitch.
Αφαιρετικές Κλάσεις και Διαπροσωπείες (Abstract Classes and Interfaces)
Learning Objectives
Readings
Notes
Learning Objectives:
Understand, describe and apply abstract classes.
Understand, describe and apply the concept of Interface.
See how interfaces are used in practice.
Learn and apply the selection sort algorithm.
Understand and apply the concept of Interfaces to develop general sorting code.
Understand and apply the definition of constants inside Interfaces.
Understand and apply the Strategy Design Pattern using interfaces.
Readings:
Chapter 8.2 Absolute Java Walter Savitch.
Chapter 13.1. Absolute Java Walter Savitch.
Πολλαπλή κληρονομικότητα (Multiple Inheritance)
Learning objectives
Readings
Notes
Learning objectives:
Understand and apply multiple inheritance through Interfaces.
Understand uses of Serializable and Clonable interface.
Understand the impact of conflicts in interface inheritance.
Default methods.
Understand and explain the concept and syntax of inner classes.
Understand, explain, and apply inner class uses.
Readings:
Chapter 13.1, Absolute Java Walter Savitch.
Chapter 13.2, 13.3 Absolute Java Walter Savitch.
Εσωτερικές κλάσεις (Inner classes)
Learning Objectives
Readings
Notes
Video
Learning Objectives:
Understand, explain, and apply static inner classes and their use.
Review simple examples of inner-class use.
Understand, explain and apply the concept of local inner classes.
Readings: Chapter 13.2, 13.3 Absolute Java Walter Savitch.
Ανώνυμες εσωτερικές κλάσεις και Πλαίσια Εφαρμογών (Anonymous Inner Classes and Application Frameworks)
Learning Objectives
Readings
Notes
Learning Objectives:
Learn, explain, and apply anonymous inner classes.
Learn, explain, and apply the Factory Design Pattern.
Apply anonymous inner classes to implement the Factory Design Pattern.
Understand, explain and apply inner classes to develop application frameworks
with event-driven programming.
Exercises on Inner Classes.
The Liskov Substitution Principle.
The Interface Segregation Principle.
Readings: Chapter 13.2, 13.3 Absolute Java Walter Savitch.
Ενότητα 5: Διαχείριση Εξαιρέσεων και
Είσοδος/'Εξοδος (Exception Handling and File I/O)
Σφάλματα και Διαχείριση Εξαιρέσεων
Learning objectives
Readings
Notes
Program Errors
Exception Handling
Programming with Exceptions
Learning outcome:
Understand the concept of exceptions and faults.
Introduction to exception handling in Java.
Understand and apply Programming Techniques for Exception Handling.
Introduction to input/output.
Understand and explain the concept of character encodings and Unicode.
Readings: Chapter 9. Absolute Java Walter Savitch.
Είσοδος/Έξοδος στη Java (Input/Output)
Learning objectives
Readings
Notes
I/O Intro
Files in Java
Binary Files
Random Access Files
Learning outcome:
Understand and apply basic concepts of file systems and I/O.
Become familiar with and be able to apply File I/O Techniques in Java.
Text and Binary Files to store and process data.
Basic Input-Output Classes of Java: Scanner, Buffered Reader.
Understand and apply the concepts of streams, text and binary files and I/O.
Mastery of the File Class.
Mastery of Binary Files.
Mastery of Random-Access Files.
Readings: Chapter 10. Absolute Java Walter Savitch.
Ενότητα 6: Γενόσημοι Τύποι, Κιβώτια και Συλλογές (Generics and Collections)
Λίστες και Γενόσημοι τύποι (ArrayList and Generics)
Learning Objectives
Readings
Notes
Learning Objectives:
Review, understand and apply the capabilities of the ArrayList class.
Understand and explain the concept of class parameters.
Understand, explain and apply the concept of Generic types and Generic Programming.
Understand, use and be familiar with the terminology of Generics.
Understand and explain the advantages offered by Generics.
Explore, understand, and explain various pitfalls regarding Generics.
Understand and explain the implementation of Generics through type erasure.
Readings: Chapter 14 Absolute Java Walter Savitch, and class-notes.
Γενόσημος προγραμματισμός (Generic Programming)
Learning Objectives
Readings
Notes
Learning Objectives:
Work on simple examples using Generics.
Readings: Chapter 14 Absolute Java Walter Savitch.
Γενόσημοι Τύποι και Συλλογές (Generics and Collections)
Learning Objectives
Readings
Notes
Learning Objectives:
Generic Methods.
Understand and explain the relation between Generics and Inheritance.
Understand, explain and apply the concept of Generic Methods.
Readings: Chapter 14, 15 Absolute Java Walter Savitch, and class-notes.
Τέλος μαθήματος.