CSE 3302 Programming Languages Chengkai Li Spring 2008 Smalltalk (cont.) Lecture 16 – OO Programming, Spring 2008 1 CSE3302 Programming Languages, UT-Arlington.

Slides:



Advertisements
Similar presentations
CS3012: Formal Languages and Compilers Static Analysis the last of the analysis phases of compilation type checking - is an operator applied to an incompatible.
Advertisements

OO Programming in Java Objectives for today: Constructors Method Overriding & Overloading Encapsulation.
CSE305 – Programming Languages Daniel R. Schlegel April 25, 2011 “Should array indices start at 0 or 1? My compromise of 0.5 was rejected without, I thought,
Lecture # 21 Chapter 6 Uptill 6.4. Type System A type system is a collection of rules for assigning type expressions to the various parts of the program.
Seven Secrets to Success – Finding Books When you think of the Library, you probably think of books… And you should!! The Mesabi Range College Library.
CSE 3302 Programming Languages Chengkai Li Fall 2007 Functional Programming Language (Introduction and Scheme) Lecture 17 – Functional Programming, Spring.
Principles of Object-Oriented Software Development The language Smalltalk.
Overseas Library Catalog – Request Item Overseas Library Catalog Request loaned item.
CS2200 Software Development Lecture: Object class A. O’Riordan, 2008.
Static and Dynamic Behavior Fall 2005 OOPD John Anthony.
Lecture # 24 SCIENCE 1 ASSOCIATE DEGREE IN EDUCATION Process Skills in Science.
Object-oriented programming and design 1 Smalltalk in a Nutshell Objects & classes Messages & methods Inheritance & metaclasses.
UML and SQL Models and Languages Database design is a process of modeling an enterprise in the real world Database.
Introduction To System Analysis and design
Xin  Syntax ◦ SELECT field1 AS title1, field2 AS title2,... ◦ FROM table1, table2 ◦ WHERE conditions  Make a query that returns all records.
Reports Manager. The Reports Manager website is Your user name is the word reports plus your school org number– reports135.
CSE 3302 Programming Languages Chengkai Li Spring 2008 Object-Oriented Programming Lecture 13 – OO Programming, Spring CSE3302 Programming Languages,
Class Diagrams Tutorial.
Object Oriented Design Jerry KotubaSYST Object Oriented Methodologies1.
How to Effectively Use the IIUM Library OPAC: Multiple Search Customer Services Division IIUM Library June 2007/yab/updated
CSE 3302 Programming Languages Chengkai Li, Weimin He Spring 2008 Syntax (cont.) Lecture 4 – Syntax (Cont.), Spring CSE3302 Programming Languages,
CSE 3302 Programming Languages Chengkai Li Spring 2008 Lecture 1 - Introduction, Spring CSE3302 Programming Languages, UT-Arlington ©Chengkai Li,
By: Sheldon Miller.  Find a computer in the library and login.
Lecture 131 CS110 Lecture 13 Thursday, March 11, 2004 Announcements –hw5 due tonight –Spring break next week –hw6 due two weeks from tonight Agenda –questions.
1. First I sit quietly on the carpet until the teacher asks me to stand. 1. First I sit quietly on the carpet until the teacher asks me to stand.
V | © OverDrive, Inc | Page 1 Demonstration: Library eBooks for Kindle Prepare for the eBook explosion by watching this short demonstration:
WebOPAC is computerized online catalogue of the materials held in library. The OPAC consist of an index of the bibliographic data cataloged in the system,
ITEC 3220A Using and Designing Database Systems Instructor: Prof Z. Yang Course Website: 3220a.htm
Computer Science & Engineering 2111 CSE 2111 Lecture NZ Function 1CSE 2111 NZ Function.
WEB-BASED CATALOGUE. ALEPH 500 Automated Library Expandable Program The new library information system of the University of Stellenbosch.
Using MLA form.  Collect information from all sources.  See MLA guide on Website for most common sources.  Generally the author’s last name is the.
Using Recursion to Convert Number to Other Number Bases Data Structures in Java with JUnit ©Rick Mercer.
CSE 3302 Programming Languages Chengkai Li, Weimin He Spring 2008 Abstract Data Types and Modules Lecture 11 – ADT and Modules, Spring CSE3302 Programming.
To view slide show use the page down key to toggle between pages. To exit press Esc. Or X to close.
CSE 3302 Programming Languages
CSE 3302 Programming Languages Chengkai Li Fall 2007 Smalltalk Lecture 14 – Smalltalk, Fall CSE3302 Programming Languages, UT-Arlington ©Chengkai.
Introduction to Objects and Encapsulation Computer Science 4 Mr. Gerb Reference: Objective: Understand Encapsulation and abstract data types.
Random Logic l Forum.NET l State Machine Mechanism Forum.NET 1 st Meeting ● December 27, 2005.
Lecture 20-something CIS 208 Wednesday, April 27 th, 2005.
Administrative Issues Lecture 22 – Prolog (III), Fall 2007 CSE3302 Programming Languages, UT-Arlington ©Chengkai Li, HW3 (due at March 18 th ) Essay.
CSE 3302 Programming Languages Chengkai Li, Weimin He Spring 2008 Control I Expressions and Statements Lecture 9 – Control I, Spring CSE3302 Programming.
CSE 3302 Programming Languages Chengkai Li Spring 2008 Functional Programming Language: Haskell (cont’d) Lecture 20 – Functional Programming, Spring 2008.
CSE6339 DATA MANAGEMENT AND ANALYSIS FOR COMPUTATIONAL JOURNALISM CSE6339, Spring 2012 Department of Computer Science and Engineering, University of Texas.
Destiny Discover eBooks
Call Numbers in the Library
CSE341: Programming Languages Lecture 21 Dynamic Dispatch Precisely, and Manually in Racket Dan Grossman Spring 2016.
Accessing the Catalog. An Introduction to Discovery: The New Catalog at the Dominican Theological Library.
Beginning with the Spring 2017 semester, WorldCat Discovery Services will replace the HELIN Catalog as the way patrons can search our library’s collection.
CSE 3302 Programming Languages
CSE341: Programming Languages Lecture 21 Dynamic Dispatch Precisely, and Manually in Racket Dan Grossman Spring 2017.
Csci 490 / Engr 596 Special Topics / Special Projects Software Design and Scala Programming Spring Semester 2010 Lecture Notes.
Using LINC, the Library Catalog
Sign in with fingerprint or facial recognition
Information Commons: Turitea Library
Place a hold on a checked out item
Checking out eBooks and Audiobooks
OO Design with Inheritance
Using “Destiny” to find books
Call Numbers in the Library
ITEC 3220A Using and Designing Database Systems
CS 331 Principles of Programming Languages
Math 7 Skills Check Retakes*
Let’s Learn About Call Numbers.
CSE 3302 Programming Languages
The parts of a scholarly book
Projecting output in MySql
CSE 3302 Programming Languages
Announcements CSE 1111 Week 6.
CSE341: Programming Languages Lecture 21 Dynamic Dispatch Precisely, and Manually in Racket Dan Grossman Spring 2019.
CSE 3302 Programming Languages
Presentation transcript:

CSE 3302 Programming Languages Chengkai Li Spring 2008 Smalltalk (cont.) Lecture 16 – OO Programming, Spring CSE3302 Programming Languages, UT-Arlington ©Chengkai Li, 2008

Correction of example in lecture 15 A>>m2 …. A subclass: #B … (not “B subclass: #A …”) B>>m2 super m2 B subclass: #C… C>>m1 self m2 aC := C new. aC m1 What will happen if the lookup of m2 starts from the superclass of message receiver? Lecture 16 – OO Programming, Spring 2008 CSE3302 Programming Languages, UT-Arlington ©Chengkai Li,

HW3 Array: reverse max Lecture 16 – OO Programming, Spring 2008 CSE3302 Programming Languages, UT-Arlington ©Chengkai Li,

An Example A library has books and clients. Client: an ID, a name, an address and a collection of the books checked out. Book: an ID, a title, an author, and a current state, which is either “checked out“ or “on shelf”. Library: a collection of customers and a collection of books that are not checked out. Lecture 16 – OO Programming, Spring 2008 CSE3302 Programming Languages, UT-Arlington ©Chengkai Li,

Define three classes Library, Book, and Client. Lecture 16 – OO Programming, Spring 2008 CSE3302 Programming Languages, UT-Arlington ©Chengkai Li,

Define the initialization methods for these three classes. Lecture 16 – OO Programming, Spring 2008 CSE3302 Programming Languages, UT-Arlington ©Chengkai Li,

Define an allBooksDo: method for Library that iterates over both the books that are checked out and the books that are not checked out. Lecture 16 – OO Programming, Spring 2008 CSE3302 Programming Languages, UT-Arlington ©Chengkai Li,

Define a booksTitled: method for Library that returns a collection of all books with a particular title. Lecture 16 – OO Programming, Spring 2008 CSE3302 Programming Languages, UT-Arlington ©Chengkai Li,

Define the checkOut: method for Client, which takes a book as an argument and assigns to to the client. Lecture 16 – OO Programming, Spring 2008 CSE3302 Programming Languages, UT-Arlington ©Chengkai Li,

Define the checkoutBy: method for Book, which is only called if the book is not checked out. Its argument is the client checking out the book. Lecture 16 – OO Programming, Spring 2008 CSE3302 Programming Languages, UT-Arlington ©Chengkai Li,

Define the customer:checksOut: method for Library, which takes a client and a book and records the fact that the client checks out the book. It should check that the book is free before letting the client to check out. Lecture 16 – OO Programming, Spring 2008 CSE3302 Programming Languages, UT-Arlington ©Chengkai Li,