20091002-Review_UML

20091002-Review_UML - scope • static property of variable...

Info iconThis preview shows pages 1–19. Sign up to view the full content.

View Full Document Right Arrow Icon
Click to edit Master subtitle style CSE115: Introduction to  Computer Science I Dr. Carl Alphonce 219 Bell Hall 645-4739 [email protected] 11
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Phones off Signs out
Background image of page 2
Announcements Advice take notes in lecture don’t rely only on slides REVIEW notes regularly bring notes to recitation Web-CAT we’re tweaking it don’t worry if you get e-mail about regrading
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Agenda Brief review Unified Modeling Language (UML) Methods in general
Background image of page 4
BRIEF REVIEW
Background image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Object class instantiation created by ‘new’ + constructor representation stored on heap
Background image of page 6
Reference an address value of ‘new’ expression
Background image of page 7

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Variable name location type value scope lifetime local variable instance variable
Background image of page 8
Expression examples of expressions ‘new’ expression variable expression (on RHS of assignment) example1.Terrarium t1; example1.Terrarium t2;
Background image of page 9

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
package organizational mechanism each class belongs to a package
Background image of page 10
class “blueprint” of an object
Background image of page 11

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
constructor used by new to initialize a new object
Background image of page 12
Background image of page 13

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Background image of page 14
Background image of page 15

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Background image of page 16
Background image of page 17

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Background image of page 18
Background image of page 19
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: scope • static property of variable • part of program text where a variable declaration holds lifetime • runtime property of variable • period of time during which variable exists in memory UML • Unified Modeling Language – industry standard • Class diagrams UML • Unified Modeling Language – express design without reference to an implementation language • For example Binary Class Relationships: directional • binary two classes are involved – source class has code modification – target class does not • composition – source: WHOLE – target: PART • in diagram: – line decoration is on source/WHOLE package cse115; public class Dog { public Dog() { } } package cse115; public class Tail { public Tail() { } } package cse115; public class Dog { private Tail _tail; public Dog() { _tail = new Tail(); } } package cse115; public class Tail { public Tail() { } }...
View Full Document

This note was uploaded on 02/13/2011 for the course CSE 115 taught by Professor Decker during the Fall '08 term at SUNY Buffalo.

Page1 / 19

20091002-Review_UML - scope • static property of variable...

This preview shows document pages 1 - 19. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online