Docsity

CMSC433 Spring 2004: Programming Language Technologies and Paradigms - Prof. Jeffrey S. Fo, Study notes of Programming Languages

Toggle sidebar
bg1
CMSC433, Spring 2004
Programming Language Technologies and
Paradigms
http://www.cs.umd.edu/class/spring2004/cmsc433
Jeff Foster
January 29, 2004
2
Course Goal
To make you a better programmer
•Deconstruct relevant programming problems
•Solve them in an object-oriented style, focusing on
–Reusability
–Maintainability (clarity)
–Design
3
Approach
•Will use the Java programming language exclusively
–But the ideas apply to other languages equally well
•Sequential object-oriented (OO) programming
–Basic principles and tools, and
–Design patterns to improve reusability and reliability
•Concurrent OO programming
–Shared-memory multi-threading (Java Thread class), and
–Distributed message passing (Java Remote Method Invocation)
4
The Need for Abstraction
found = false;
for (int i = 0; i < a.length; i++)
if (a[i] == e) {
z = i;
found = true;
}
found = false;
for (int i = a.length-1; i >= 0; i--)
if (a[i] == e) {
z = i;
found = true;
}
Fragment 1:
Fragment 2:
5
Abstraction
•A better abstraction may be
•Improves
–Reusability
–Maintainability
•Abstraction is the key to good design
found = a.isIn(e);
if (found)
z = a.indexOf(e);
6
Topics
•Java review (2-3 lectures)
•Programming techniques and tools
–Specifications and testing
•Design patterns
•Refactoring
•Concurrency
–Concurrent programming in Java
–Design patterns
– Distributed programming
•To be determined
–Possibilities include security, event-based programming,
reflection, memory management, ...?
pf3
pf4

Partial preview of the text

Download CMSC433 Spring 2004: Programming Language Technologies and Paradigms - Prof. Jeffrey S. Fo and more Study notes Programming Languages in PDF only on Docsity!

CMSC433, Spring 2004

Programming Language Technologies and

Paradigms

http://www.cs.umd.edu/class/spring2004/cmsc

Jeff Foster

January 29, 2004

2

Course Goal

To make you a better programmer

• Deconstruct relevant programming problems

• Solve them in an object-oriented style, focusing on

– Reusability

– Maintainability (clarity)

– Design

3

Approach

• Will use the Java programming language exclusively

  • But the ideas apply to other languages equally well

• Sequential object-oriented (OO) programming

  • Basic principles and tools, and
  • Design patterns to improve reusability and reliability

• Concurrent OO programming

  • Shared-memory multi-threading (Java Thread class), and
  • Distributed message passing (Java Remote Method Invocation) 4

The Need for Abstraction

found = false; for (int i = 0; i < a.length; i++) if (a[i] == e) { z = i; found = true; } found = false; for (int i = a.length-1; i >= 0; i--) if (a[i] == e) { z = i; found = true; }

Fragment 1:

Fragment 2:

Abstraction

• A better abstraction may be

• Improves

– Reusability

– Maintainability

• Abstraction is the key to good design

found = a.isIn(e); if (found) z = a.indexOf(e);

Topics

• Java review (2-3 lectures)

• Programming techniques and tools

  • Specifications and testing

• Design patterns

• Refactoring

• Concurrency

  • Concurrent programming in Java
  • Design patterns
  • Distributed programming

• To be determined

  • Possibilities include security, event-based programming, reflection, memory management, ...?

7

Style

• Interaction

– This is your course: what do you want to learn?

• Discussion

– Not just professor/TA to student, but student to student,

with regard to ideas, techniques, and solutions

• Learn by doing

– If you don’t put effort into the programming projects,

you will learn very little

8

Textbooks

• Primary Texts

– Barbara Liskov and John Guttag, Program

Development in Java

– Bruce Eckel, Thinking in Java (3rd Edition)

  • Java primer
  • A complete copy of the book can be downloaded for free

• See web page for more useful resources

9

Class Accounts

• We will have accounts on CSIC machines

– Linux cluster; RedHat 9

– Lab is in room 3107 CSIC

• Class accounts will be emailed Friday morning

– To the email account registered with UMEG

  • So make sure you check or forward that account!
  • Right after class: check your e-mail address on TESTUDO

– If you don’t get an account by Friday, e-mail us

• You may work on any machine you like, but...

– Make sure you code runs on the linux lab 10

Software

• Will be using Java 1.4.

– http://java.sun.com/j2se/1.4.2/docs/api

• May wish to use the Dr Java IDE or Eclipse IDE

– Installed on all CSIC machines

– http://drjava.sourceforge.net/

– http://www.eclipse.org

• Will make use of JUnit testing package

– Part of hw #2, may want to use later yourself

– http://www.junit.org

Projects

• Focus on networked applications

– Encourages modular, abstract design

– Admits natural use of concurrency and distribution

– Relevant in our connected society

• Start small and build up

– Develop a sophisticated family of software by course’s

end

Project Submission

• Projects due at 6pm on due date

– By Unix time of day

– You must submit a good-faith effort

  • You can be failed for the course if you do not

– Late submission up to 9am the next morning

  • Score is multiplied by 0.

• Online submission procedure (details later)

– Submit early and often

– E-mail course staff to recover previous submit

  • Don’t rely on us, though – back up your own work

Stay up to date

http://www.cs.umd.edu/class/spring2004/cmsc

Contains:

• Announcements

• Lecture notes

• Project assignments

• Resources

• And more!