GridWorld Case Study Part 3 GridWorld Classes and Interfaces A Summary by Jim Mims.

Slides:



Advertisements
Similar presentations
GridWorld Case Study The Classes A Summary by Jim Mims.
Advertisements

GridWorld Case Study Part 1 Experiments to Observe Attributes and Behavior of Actors A Summary by Jim Mims.
GridWorld Case Study Part 2 Bug Variations A Summary by Jim Mims.
GridWorld Case Study Part 4 Classes that Extend the Critter Interface A Summary by Jim Mims.
GridWorld Case Study Part 5 Grid Data Structures Not Tested on A Exam A Summary by Jim Mims.
Use Case Diagrams Damian Gordon.
© A+ Computer Science - GridWorld © A+ Computer Science -
Critters A Study in Design Patterns. Design Patterns  Not specific algorithms or data structures  A general reusable solution to a common problem.
1 CSC 222: Computer Programming II Spring 2005 Inheritance  derived class, parent class  inheriting fields & methods, overriding fields and methods 
OOP Design Patterns Chapters Design Patterns The main idea behind design patterns is to extract the high level interactions between objects and.
Object-Oriented Analysis and Design
UML – Class Diagrams.
CHAPTER 3 COLLECTIONS Abstract Data Types. 2 A data type consists of a set of values or elements, called its domain, and a set of operators acting on.
Object-Oriented Databases v OO systems associated with – graphical user interface (GUI) – powerful modeling techniques – advanced data management capabilities.
Object Classes In UML. Object Concepts What is an object? How do objects communicate? How is an object’s interface defined? What have objects to do with.
Objects First with Java A Practical Introduction using BlueJ
Basic OOP Concepts and Terms
Use Cases Chapter 4. After Scenarios Find all the use cases in the scenario that specifies all possible instances of how to report a fire –Ex: “Report.
C++ Training Datascope Lawrence D’Antonio Lecture 11 UML.
5.0 Objects First with Java A Practical Introduction using BlueJ David J. Barnes Michael Kölling.
BY VEDASHREE GOVINDA GOWDA
GridWorld Case Study1 Barbara Ericson Georgia Tech Jan 2008.
Copyright 2002 Prentice-Hall, Inc. Modern Systems Analysis and Design Third Edition Jeffrey A. Hoffer Joey F. George Joseph S. Valacich Chapter 20 Object-Oriented.
SOFTWARE DESIGN AND ARCHITECTURE LECTURE 27. Review UML dynamic view – State Diagrams.
© A+ Computer Science - Row = 0 Column = 0.
GridWorld Case Study Barbara Ericson March 24, 2007.
1 Structuring Systems Requirements Use Case Description and Diagrams.
Java Arrays  Java has a static array capable of multi-dimensions.  Java has a dynamic array, which is also capable of multi-dimensions.  The ArrayList.
Design Patterns -- Omkar. Introduction  When do we use design patterns  Uses of design patterns  Classification of design patterns  Creational design.
CS 4233 Review Feb February Review2 Outline  Previous Business – My.wpi.edu contains all grades to date for course – Review and contact.
Define an interface for creating an object, but let subclasses decide which class to instantiate.
© Copyright 1992–2004 by Deitel & Associates, Inc. and Pearson Education Inc. All Rights Reserved. Chapter 26 - Java Object-Based Programming Outline 26.1Introduction.
Object Oriented Programming
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.
The GridWorld Case Study Program Section 1 - Overview of the Class Hierarchies Section 2 - The Actor Class Section 3 - The Rock and Flower Classes Section.
Use Cases and Use Case Diagrams Reporter: 陳雅萍. Outline Use cases, actors Organizing use cases Modeling the behavior of an element Use case diagrams Common.
Slide 0. Inheritance and Polymorphism Mr. Landa South East High.
GridWorld Case Study The case study is a program that simulates actions and interactions of objects in a two- dimensional grid. During a single step of.
Object orientation and Packaging in Java Object Orientation and Packaging Introduction: After completing this chapter, you will be able to identify.
Introduction to Objects and Encapsulation Computer Science 4 Mr. Gerb Reference: Objective: Understand Encapsulation and abstract data types.
Technician Table Editor Academic advisor : Professor Ehud Gudes Technical advisor : Menny Even Danan Team: Olga Peled Doron Avinoam Ira Zaitsev ADD Presentation.
Introduction to UML and Rational Rose UML - Unified Modeling Language Rational Rose 98 - a GUI tool to systematically develop software through the following.
6.0 Objects First with Java A Practical Introduction using BlueJ David J. Barnes Michael Kölling.
Chapter 5 Introduction to Defining Classes Fundamentals of Java.
Geoff Holmes and Bernhard Pfahringer COMP206-08S General Programming 2.
Object Oriented Programming (OOP) is a style of programming that incorporates these 3 features: Encapsulation Polymorphism Class Interaction.
GridWorld.
Sections Inheritance and Abstract Classes
Objects First with Java A Practical Introduction using BlueJ
GridWorld Part 4 Meet the Critters.
Agenda About Quiz ChameleonCritter class CrabCritter class homework.
Barbara Ericson Georgia Tech Jan 2008
Objects First with Java A Practical Introduction using BlueJ
CS102 – Bilkent University
Unified Modeling Language
COS 260 DAY 2 Tony Gauvin.
© A+ Computer Science - GridWorld © A+ Computer Science -
© A+ Computer Science - GridWorld © A+ Computer Science -
A closer look at the world
Objects First with Java A Practical Introduction using BlueJ
GridWorld Part 4 Meet the Critters.
© A+ Computer Science - GridWorld The GridWorld case study provides a graphical environment where visual objects inhabit and interact.
Basic OOP Concepts and Terms
© A+ Computer Science - GridWorld © A+ Computer Science -
Objects First with Java A Practical Introduction using BlueJ
GridWorld Case Study.
© A+ Computer Science - GridWorld © A+ Computer Science -
© A+ Computer Science - GridWorld © A+ Computer Science -
Presentation transcript:

GridWorld Case Study Part 3 GridWorld Classes and Interfaces A Summary by Jim Mims

Contents Introduction Part 1: Observing and Experimenting with GridWorld Part 2: Bug Variations Part 3: GridWorld Classes and Interfaces Part 4: Classes that Extend the Critter Class Part 5: Grid Data Structures

Classes and Interfaces: Relationships

Introduction The case study provides a graphical environment where visual objects inhabit and interact in a two-dimensional grid. Students design and creator actor objects, add them to a grid, and determine whether they behave according to specifications.

GridWorld Classes and Interfaces: Location Class Encapsulates coordinates for an actors position in the grid Every actor has a position and a direction Class provides 8 constants that specify compass directions Class provides 7 constants for turn directions

GridWorld Classes and Interfaces: Grid Interface Specifies the method for any grid that contain objects of type E BoundedGrid and UnboundedGrid implement the interface Methods allow you to put objects into a grid remove them get reference to an object in the grid Four other methods are used to collect information ref neighbors

GridWorld Classes and Interfaces: Actor Class Accessor methods provide information concerning state of the actor getColor getDirection) getGrid() getLocation() Mutator methods enable an actor to add or remove itself from a grid putSelfInGrid() removeSElfFromGrid() Additional methods that can be used setColor() setDirection() act()

GridWorld Classes and Interfaces: Extending Actor Class Bug, Flower, Rock classes override act method of the Actor class The behavior of these class is specified by how they override act()

Graphical User Interface is Not Tested World class makes connection between GUI and classes that are tested ActorWorld is a subclass of World ActorWorld provides a step method that invokes act on each actor Other worlds can be defined that contain occupants other than actors