CS106A, Stanford University

Slides:



Advertisements
Similar presentations
Written by: Dr. JJ Shepherd
Advertisements

Object Orientated Concepts. Overview  The world is objects  Defining an object  Not a function, it’s a method  Lets inherit want we can  Objects.
CSE 115 Week 10 March , Announcements March 21 – Lab 7 Q & A in lecture March 21 – Lab 7 Q & A in lecture March 26 – Exam 7 March 26 – Exam.
Objects First with Java A Practical Introduction using BlueJ
OOP Project Develop an Application which incorporates the following OO Mechanisms and Principals: – Classes Visibility Constructor(s) Class Variable (if.
UML Class Diagram: class Rectangle
CSE 250: Data Structures Week 3 January 28 – February 1, 2008.
Fall 2005CSE 115/503 Introduction to Computer Science I1 Composition details Recall, composition involves 3 things: –Declaration of instance variable of.
5.0 Objects First with Java A Practical Introduction using BlueJ David J. Barnes Michael Kölling.
Abstraction: Polymorphism, pt. 1 Abstracting Objects.
CS200 Algorithms and Data StructuresColorado State University Part 4. Advanced Java Topics Instructor: Sangmi Pallickara
Designing Classes Prelude © 2015 Pearson Education, Inc., Upper Saddle River, NJ. All rights reserved. Data Structures and Abstractions with Java, 4e Frank.
(1) ICS 313: Programming Language Theory Chapter 12: Object Oriented Programming.
Interfaces Chapter 9. 9 Creating Interfaces An interface is a contract. Every class that implements the interface must provide the interface’s defined.
The Distributive Property You will be able to use the distributive property You will be able to simplify expressions with like terms.
Unit 8: Course Summary. Visual 8.2Unit 8: Course Summary Review I-300 Course Objectives Are you now able to:  Describe how the NIMS Command and Management.
Basic Concepts of OOP.  Object-Oriented Programming (OOP) is a type of programming added to php5 that makes building complex, modular and reusable web.
Visual 8.1 Course Summary Unit 8: Course Summary.
Visual 8.1 Course Summary Unit 8: Course Summary.
C++ General Characteristics: - Mixed typing system - Constructors and destructors - Elaborate access controls to class entities.
Slides prepared by Rose Williams, Binghamton University ICS201 Lecture 7 : Interfaces King Fahd University of Petroleum & Minerals College of Computer.
Java Programming: Guided Learning with Early Objects Chapter 9 Inheritance and Polymorphism.
Computer Programming II Lecture 5. Introduction to Object Oriented Programming (OOP) - There are two common programming methods : procedural programming.
Written by: Dr. JJ Shepherd
Web Design & Development Lecture 9
Java Events. Java Events Important definitions Overridden method Class vs. abstract class vs. interface Event Handling Definition Main components Windows.
The Distributive Property
Direct Variation.
CS106A, Stanford University
Packages, Interfaces & Exception Handling
CS106A, Stanford University
Strategy Design Pattern
UML Class Diagram: class Rectangle
Using local variable without initialization is an error.
CS 106A, Lecture 24 Interactors and NameSurfer
Object-Oriented Programming
Objects First with Java A Practical Introduction using BlueJ
CS106A, Stanford University
The Scientific Method Way of Problem Solving.
CS106A, Stanford University
CS 106A, Lecture 22 More Classes
CS106A, Stanford University
Inheritance Basics Programming with Inheritance
Interface.
The Boolean (logical) data type boolean
Mole concept.
Physics-based simulation for visual computing applications
Interfaces.
CS106A, Stanford University
Advanced Java Programming
CSE 1030: Implementing GUI Mark Shtern.
CS106A, Stanford University
Abstract Classes Page
Computer Programming with JAVA
CS106A, Stanford University
Essential Question: How do scientists develop explanations?
Java Inheritance.
What details, symbols, actions, and words do you see in this political cartoon that make you think about what is happening? 1.3A.
Objects First with Java A Practical Introduction using BlueJ
CS106A, Stanford University
STORE MANAGER RESPONSIBILITIES.
“Reinforcing Kinetic and Potential energy with Scratch”
CS106A, Stanford University
CS106A, Stanford University
Objects First with Java A Practical Introduction using BlueJ
CS106A, Stanford University
Review of Previous Lesson
Use of GEANT4 in CMS The OSCAR Project
Entry Guideline Template
For More Details:
Presentation transcript:

CS106A, Stanford University Data Visualization Chris Piech CS106A, Stanford University

Be able to create a variable type from scratch Learning Goals Be able to create a variable type from scratch

A class defines a new variable type

You must define three things 1. What variables does each instance store? 2. What methods can you call on an instance? 3. What happens when you make a new one? *details on how to define these three things coming soon

https://www.youtube.com/watch?v=jbkSRLYSojo

extends Make a class inherit all the instance variables and methods of another class

public class Simulator extends GraphicsProgram { // class definition }

public class NameSurferGraph extends GCanvas { // class definition }

I promise that this class will define implements I promise that this class will define a few given methods

public class GRect extends Gobject implements GFillable { // class definition }

implements Also a cheeky way to share constants between classes I promise that this class will define a few given methods

public class NameSurferDatabase implements NameSurferConstants { // class definition }