Software Engineering with Java - Computer Science & Engineering

Download Report

Transcript Software Engineering with Java - Computer Science & Engineering

The Big Picture
of Software Development
Glenn Blank
Professor of Computer Science
Lehigh University
National Trends

The pipeline for women and minorities entering
computer science (CS) and information technology (IT)
is shrinking, at a time when the projected demand
for IT professionals is growing


“We must take direct action to attract and retain more
women to computing at all points in the pipeline (i.e.,
K-12, undergraduate, graduate, faculty and industry)…”



Camp, 1997, 1999, Cohoon, 2002
Camp 1999
Do you agree? What does this situation mean for you?
That’s why there’s Launch-IT!
Creating Software is like
Building a House

1.
2.
3.
4.



When building a house, the first thing you do is:
Buy some lumber and nails to frame it
Dig a hole for the foundation
Get a loan from a bank to pay for it
None of the above
First, contractor figures out what the customer wants!
Next, architect designs a blueprint
Next… well, why don’t you figure it out?
How is creating software like
building a house?








Figure out what customer wants: Requirements
Sketch a plan: Conceptual design
Blueprint: Architectural design
Get a loan: Cost analysis/risk assessment
Subcontractors: Team with specialists; outsource
Build it: Implementation
Inspect and fix problems: Testing
Maintenance and remodeling: Maintenance
(new releases and versions)
Multimedia about
software engineering
Objects

Software objects model real-world objects


For example, trees, cars, ATMs
Objects are “natural”

We interact with them all the time
(vs. lines of code or functions)
Objects and Classes



Objects are categorized by their type, or class
An object is an instance of a class
A software object has a current state and a set
of possible behaviors

Attributes describe properties of a class of objects


A car has an make, model, color, etc.
Methods perform behaviors of a class of objects

A car can start, accelerate, reverse, park, etc.
Objects and Classes example

Object: Sue (Class: person)
Attributes: height (5’), hairColor (blond), eyeColor (blue)
 Methods: getHeight, getHairColor, getEyeColor,
setHeight, setHairColor, setEyeColor


Object: Mike (Class: person)
Attributes: height (6’), hairColor (black), eyeColor (hazel)
 Methods: getHeight, getHairColor, getEyeColor,
setHeight, setHairColor, setEyeColor



What do object instances have in common?
How are objects instances different?
Multimedia about
Classes and objects
Everyone gets a CIMEL login
CIMEL means
Constructive Inquiry-Based Multimedia E-Learning
JVM

Java programming language compiler (javac)


A program that translates Java language source code
into the Java Virtual Machine (JVM) byte codes
JVM – Java Virtual Machine
A program that interprets and executes byte codes
 Can interpret and execute Java byte codes on any
computer platform (PC, Mac, Unix)

Integrated Development
Environment
 IDE
 An
environment where programmers
develop software
 Eclipse is an industrial strength IDE
 DrJava is a novice-oriented IDE
Object Oriented Software Design

Design a system as a set of classes



OO software encourages software reuse



Expresses as a class diagram
Unified Modeling Language (UML) is a standard
For example, reuse input/output, graphics classes
Java comes with a large library of reusable classes
Why is reuse a good idea?



Avoid re-inventing the wheel—cuts costs
Lets developers focus on new things
Reliability: reusable software gets tested more