COS 260 DAY 2 Tony Gauvin.

Slides:



Advertisements
Similar presentations
CM10134-CM50147 Programming I Basic Programming in Java Marina De Vos.
Advertisements

Objects and Classes First Programming Concepts. 14/10/2004Lecture 1a: Introduction 2 Fundamental Concepts object class method parameter data type.
1 Programming for Engineers in Python Autumn Lecture 5: Object Oriented Programming.
Objects First with Java A Practical Introduction using BlueJ
Understanding class definitions Looking inside classes 3.0.
Aalborg Media Lab 21-Jun-15 Software Design Lecture 1 “ Introduction to Java and OOP”
About the Presentations The presentations cover the objectives found in the opening of each chapter. All chapter objectives are listed in the beginning.
Introduction to Programming. To gain a sound knowledge of programming principles To gain a sound knowledge of object- orientation To be able to critically.
CO320 Introduction to Object- Oriented Programming Michael Kölling 3.0.
5.0 Objects First with Java A Practical Introduction using BlueJ David J. Barnes Michael Kölling.
Introduction To System Analysis and design
Starting Chapter 4 Starting. 1 Course Outline* Covered in first half until Dr. Li takes over. JAVA and OO: Review what is Object Oriented Programming.
1 Programming James King 12 August Aims Give overview of concepts addressed in Web based programming module Teach you enough Java to write simple.
Introduction to Object-oriented programming and software development Lecture 1.
An Object-Oriented Approach to Programming Logic and Design
5.0 Objects First with Java A Practical Introduction using BlueJ Introduction to Computer Science I Instructor: Allyson Anderson.
Object Oriented Design: Identifying Objects
Objects First With Java A Practical Introduction Using BlueJ Designing applications 1.0.
Introduction to Java. 2 Textbook David J. Barnes & Michael Kölling Objects First with Java A Practical Introduction using BlueJ Fourth edition, Pearson.
OBJECTS AND CLASSES CITS1001. Concepts for this lecture class; object; instance method; parameter; signature data type multiple instances; state method.
1 COS 260 DAY 2 Tony Gauvin. 2 Agenda Questions? Class roll call Blackboard Web Resources Objects and classes 1 st Mini quiz on chap1 terms and concepts.
1 COS 260 DAY 1 Tony Gauvin. 2 Agenda Class roll call Instructor Introduction Instructor’s Educational Philosophy Contract on Classroom Behavior Syllabus.
Well-behaved objects Main concepts to be covered Testing Debugging Test automation Writing for maintainability Objects First with Java - A Practical.
Designing applications Main concepts to be covered Discovering classes CRC cards Designing interfaces Patterns Objects First with Java - A Practical.
5.0 Objects First with Java A Practical Introduction using BlueJ David J. Barnes Michael Kölling.
Final Review. From ArrayLists to Arrays The ArrayList : used to organize a list of objects –It is a class in the Java API –the ArrayList class uses an.
1 COS 260 DAY 14 Tony Gauvin. 2 Agenda Questions? 6 th Mini quiz graded  Oct 29 –Chapter 6 Assignment 4 will be posted later Today –First two problems.
JAVA: An Introduction to Problem Solving & Programming, 7 th Ed. By Walter Savitch ISBN © 2015 Pearson Education, Inc., Upper Saddle River,
1 COS 260 DAY 12 Tony Gauvin. 2 Agenda Questions? 5 th Mini quiz –Chapter 5 40 min Assignment 3 Due Assignment 4 will be posted later (next week) –If.
1 COS 260 DAY 21 Tony Gauvin. 2 Agenda Questions? 8 th Mini Quiz corrected –Good results 9 Th Mini Quiz Today –40 min covering Chap 9 Assignment 5 Due.
Programming. To gain a sound knowledge of programming principles To gain a sound knowledge of object- orientation To be able to critically assess the.
1 COS 260 DAY 22 Tony Gauvin. 2 Agenda Questions? 9 th Mini Quiz corrected –Good results Assignment 5 Not corrected yet Assignment 6 Posted (one more)
6.0 Objects First with Java A Practical Introduction using BlueJ David J. Barnes Michael Kölling.
Well-behaved objects Main concepts to be covered Testing Debugging Test automation Writing for maintainability © 2017 Pearson Education, Inc. Hoboken,
CSC 222: Object-Oriented Programming
Data Abstraction: The Walls
Object-Oriented Programming Concepts
Objects and Classes CITS1001 week 1.
COS 260 DAY 1 Tony Gauvin.
Objects First with Java A Practical Introduction using BlueJ
CSC 221: Computer Programming I Spring 2010
CSC 221: Computer Programming I Fall 2005
Reference: COS240 Syllabus
About the Presentations
Object Oriented Programming
Object-Orientated Programming
Functional Processing of Collections (Advanced)
Section 11.1 Class Variables and Methods
COS 260 DAY 17 Tony Gauvin.
COS 260 DAY 23 Tony Gauvin.
Object-Oriented Programming
Understanding class definitions
Objects First with Java A Practical Introduction using BlueJ
COS 260 DAY 13 Tony Gauvin.
COS 260 DAY 6 Tony Gauvin.
COS 260 DAY 11 Tony Gauvin.
COS 260 DAY 16 Tony Gauvin.
COS 260 DAY 10 Tony Gauvin.
COS 260 DAY 18 Tony Gauvin.
COS 260 DAY 3 Tony Gauvin.
COS 260 DAY 16 Tony Gauvin.
Objects First with Java A Practical Introduction using BlueJ
COS 260 DAY 11 Tony Gauvin.
COS 260 DAY 23 Tony Gauvin.
COS 260 DAY 14 Tony Gauvin.
COS 260 DAY 4 Tony Gauvin.
COS 260 DAY 23 Tony Gauvin.
Objects First with Java A Practical Introduction using BlueJ
COS 260 DAY 6 Tony Gauvin.
Further abstraction techniques
Presentation transcript:

COS 260 DAY 2 Tony Gauvin

Agenda Class roll call Blackboard Web Resources General Information about class Assignment 1 posted Due September 15 Miniquiz 1 September 5 30 min, open book Less than 10 questions over chapter 1 Objects and classes

Class Documents Syllabus Contract on Classroom behavior Class Slides http://perleybrook.umfk.maine.edu/slides/fall2017/COS260/ 11/30/2018

Additional Course Documents Contract on Classroom Behavior UMFK Academic Integrity Policy UMFK Faculty Position on Academic Decorum UMS Student Conduct Code

Web Resources Java Website (Oracle) JGrasp Blackboard https://www.courses.maine.edu Textbook Web Site https://www.bluej.org/objects-first/index.html Java Website (Oracle) https://www.oracle.com/java/index.html https://www.java.com/en/ BlueJ https://www.bluej.org/ JGrasp http://www.jgrasp.org/ Other Useful Sites Http://www.javaworld.com http://www.java2s.com/Tutorial/Java/CatalogJava.htm

Objects First with Java A Practical Introduction using BlueJ David J. Barnes Michael Kölling Replace this with your course title and your name/contact details. 6.0 © David J. Barnes and Michael Kölling

Objects First with Java Course Contents Introduction to object-oriented programming… …with a strong software engineering foundation… …aimed at producing and maintaining large, high-quality software systems. © 2017 Pearson Education, Inc. Hoboken, NJ. All rights reserved. © David J. Barnes and Michael Kölling

Objects First with Java Buzzwords responsibility-driven design inheritance encapsulation iterators overriding coupling cohesion javadoc interface collection classes mutator methods polymorphic method calls © 2017 Pearson Education, Inc. Hoboken, NJ. All rights reserved. © David J. Barnes and Michael Kölling

Goals Sound knowledge of programming principles Sound knowledge of object-orientation Able to critically assess the quality of a (small) software system Able to implement a small software system in Java © 2017 Pearson Education, Inc. Hoboken, NJ. All rights reserved.

Book David J. Barnes & Michael Kölling Objects First with Java A Practical Introduction using BlueJ 6th edition, Pearson Education, 2017 © 2017 Pearson Education, Inc. Hoboken, NJ. All rights reserved.

Course overview (1) Objects and classes Understanding class definitions Object interaction Grouping objects More sophisticated behavior - libraries Designing classes Well-behaved objects - testing, maintaining, debugging © 2017 Pearson Education, Inc. Hoboken, NJ. All rights reserved.

Course overview (2) Inheritance Polymorphism Extendable, flexible class structures Building graphical user interfaces Handling errors Designing applications © 2017 Pearson Education, Inc. Hoboken, NJ. All rights reserved.

Advanced material There is advanced material on: Streams; Chap 5 Lambdas; Chap 5 2D arrays; Chap 7 This may be skipped on first reading … ... or read, according to preference! © 2017 Pearson Education, Inc. Hoboken, NJ. All rights reserved.

Classes and objects Fundamental to much of the early parts of this course. Class: category or type of ‘thing’. Like a template or blueprint. Object: belongs to a particular class and has individual characteristics. Explore through BlueJ … © 2017 Pearson Education, Inc. Hoboken, NJ. All rights reserved.

Demo of figures project Objects First with Java Demo of figures project Here, I start discussing objects and classes. I talk to the students about it for a while, then I do an extensive demo of the shapes example in BlueJ. All important points of this lecture are encountered and pointed out during this demo. All following slides serve only as summary, or reminder. No new material is introduced after the demo. figures.zip © 2017 Pearson Education, Inc. Hoboken, NJ. All rights reserved. © David J. Barnes and Michael Kölling

Objects First with Java Fundamental concepts It is vital to understand these concepts as soon as possible. object class method parameter data type © 2017 Pearson Education, Inc. Hoboken, NJ. All rights reserved. © David J. Barnes and Michael Kölling

© 2017 Pearson Education, Inc. Hoboken, NJ. All rights reserved.

Objects First with Java Class Object Here, I start discussing objects and classes. I talk to the students about it for a while, then I do an extensive demo of the shapes example in BlueJ. All important points of this lecture are encountered and pointed out during this demo. All following slides serve only as summary, or reminder. No new material is introduced after the demo. Objects First with Java - A Practical Introduction using BlueJ, © David J. Barnes, Michael Kölling © David J. Barnes and Michael Kölling

Classes and Objects A class (abstractions) Objects (concrete) represents all similar objects of a kind (example: “car”) Objects (concrete) represent ‘things’ from the real world, or from some problem domain; example: “that red car in the parking lot”. © 2017 Pearson Education, Inc. Hoboken, NJ. All rights reserved.

Classes & Objects http://phpenthusiast.com/object-oriented-php-tutorials/create-classes-and-objects © 2017 Pearson Education, Inc. Hoboken, NJ. All rights reserved.

Methods and Parameters Objects have operations which can be invoked (Java calls them methods). Methods may have parameters to pass additional information needed to execute. Parameters introduce variation into the effect of method calls. © 2017 Pearson Education, Inc. Hoboken, NJ. All rights reserved.

Other observations Many distinct instances can be created from a single class. An object has attributes: values stored in fields. The class defines what fields an object has, but each object stores its own set of values (the state of the object). © 2017 Pearson Education, Inc. Hoboken, NJ. All rights reserved.

State © 2017 Pearson Education, Inc. Hoboken, NJ. All rights reserved.

Two circle objects © 2017 Pearson Education, Inc. Hoboken, NJ. All rights reserved.

Source code Each class has source code associated with it that defines its details (attributes and methods). The source code is written to obey the rules of a particular programming language. We will explore this in detail in the next chapter. © 2017 Pearson Education, Inc. Hoboken, NJ. All rights reserved.

Return values All the methods in the figures project have void return types; but … … methods may return a result via a return value. Such methods have a non-void return type. More on this in the next chapter. © 2017 Pearson Education, Inc. Hoboken, NJ. All rights reserved.

Make this Image using Figures Project © 2017 Pearson Education, Inc. Hoboken, NJ. All rights reserved.

Review Classes model concepts. Source code realises those concepts. Source code defines: What objects can do (methods). What data they store (attributes). Objects come into existence with pre-defined attribute values. The methods determine what objects do with their data. © 2017 Pearson Education, Inc. Hoboken, NJ. All rights reserved.

Review When a method is called an object: Alters its state, and/or Uses its data to decide what to do. Some methods take parameters that affect their actions. Methods without parameters typically use their state to decide what to do. Some methods return a value. © 2017 Pearson Education, Inc. Hoboken, NJ. All rights reserved.

Review Most programs contain multiple classes. At runtime, objects interact with each other to realize the overall effect of the program. © 2017 Pearson Education, Inc. Hoboken, NJ. All rights reserved.