Next:
Contents
Contents
Introduction to Java
and
OOA/OOD
for
Web Applications
Alvin J. Alexander
502.493.1050
http://www.devdaily.com
Copyright 2002 DevDaily Interactive (http://devdaily.com).
All Rights Reserved.
Contents
Day 1: Object-Oriented Software Development
Why OO?
Benefits of object-oriented programming
Symptoms of software development problems
Root causes of project failure
Software development best practices
Introduction to OO concepts
Encapsulation
Inheritance
Polymorphism
Abstraction with objects
Message passing
UML summary
Standard diagrams
Use Case diagram
Class diagram
Sequence diagram
Collaboration diagram
Package diagram
State diagram
Activity diagram
Component diagram
Deployment diagram
Object Oriented Software Development
Why have a process?
The Rational Unified Process (RUP)
Inception phase
Objectives
Activities
Artifacts
Elaboration
Purpose
Objectives
Activities
Outcome/Deliverables
Other artifacts
Construction phase
Objectives
Activities
Deliverables
Transition
Purpose
Objectives
Activities
A sample process
Domain modeling
What is a class?
Discover classes
Build generalization relationships
Build associations between classes
Mine legacy documentation for domain classes
Wrapping up domain modeling
Use case modeling
Actors
Robustness analysis
Definitions
Key roles of robustness analysis
Closer look at object types
Performing robustness analysis
Interaction modeling
Introduction
Goals of Interaction Modeling
Sequence Diagrams
Getting Started
Putting Methods on Classes
Completing Interaction Modeling
Collaboration and State Modeling
Introduction
Collaboration diagrams
State diagrams
Activity diagrams
Addressing Requirements
Introduction
Objectives
What is a Requirement?
Use Cases and Requirements
Requirements Traceability
Survey of Design Patterns
Factory pattern example
Agile Methods
The Agile Alliance
Introduction to Extreme Programming
Risk: The Basic Problem
Four Variables
The Cost of Change
Four Values
Basic Principles
Back to Basics
The Solution
OO Summary
OO Concepts
UML
Day 2: The Java Programming Language
Introduction
Chapter objectives
Java design goals
What is Java?
How/where to get Java
First Steps with Java
Java Commands and Utilities
A first application
main
Variables, constants, and keywords
Primitive data types
Literals
boolean
literals
char
literals
Floating-point
literals
String
literals
Constants
Reserved keywords
Arrays
Strings
String objects
StringBuffer
class
Exercise
Exercise
Comments and Javadoc
Types of comments
Javadoc comment tags
@see
@param
@return
@exception
@deprecated
@author
@version
@since
A comment example
Notes on Usage
Flow control and loops
Introduction
Objectives
Statements and blocks
Expressions that can be made into statements
Declaration statements
if-else
switch
while and do-while
for
Labels
break
continue
return
No
goto
Statement
Classes and objects
Introduction
Objectives
A Simple Class
Fields
Access Control and Inheritance
Creating Objects
Constructors
Constructor example
Methods
Parameter values
Using methods to control access
this
Overloading methods
Overriding methods
Static members
Initialization Blocks
Garbage collection and finalize
finalize
The
toString()
Method
Native Methods
Methods and parameters
Methods
Invoking a Method
The this Reference
Extending Classes
Introduction
Objectives
An extended class
A simple example
What protected really means
Constructors in extended classes
Constructor order dependencies
Constructor phases
Constructor phase example
Overriding methods, hiding fields, and nested classes
Overriding
The
super
keyword
Marking methods and classes
final
The
object
class
Object's utility methods
Anonymous classes
Abstract Classes and methods
Cloning objects
Three major considerations in writing a clone method
Four different attitudes a class can have towards clone
Extending classes: how and when
Designing a class to be extended
Bad effects of public fields
Non-final classes have two interfaces
Interfaces
Introduction
Objectives
An example interface
Nested classes and interfaces
Single inheritance versus multiple inheritance
Extending Interfaces
Name Conflicts
Implementing Interfaces
Using an Implementation
Marker Interfaces
When to Use Interfaces
Two Important Differences Between Interfaces and Abstract Classes
Interface or Abstract Class
Exceptions
Introduction
Objectives
Creating exception types
throw
The throws clause
Choices when invoking a method that has a throws clause
try, catch, and finally
finally
When to use exceptions
Packages
Introduction
Package Naming
Package Access
Package Contents
Examples
Day 3: Standard Libraries & Server-side Programming
Objectives
IO: Streams and readers
Java networking
Introduction
Socket
ServerSocket
ServerSocket lifecycle
URL
URLConnection
Threads
Objectives
Applications without multiple threads
Thread states
Creating a threaded class with
thread
Creating a threaded class with the
runnable
interface
Thread methods
Thread references
JavaBeans
Remote Method Invocation (RMI)
Java Native Interface (JNI)
Collections framework
Lists
Maps
Collection Utilities
Internationalization, localization, and formatting
HTTP protocol
Request and Response
Cookies
Servlets and JSPs
Objectives
Introduction/Background
Servlets
Objectives
Servlet basics
HelloWorldServlet
Servlet lifecycle
HTTPServlet
HTTPServletRequest
HTTPServletResponse
JavaServer Pages
What is a JSP?
JSP engine/container:
Translation time and request time
Scriptlets
Expressions
Declarations
Directives
page
directive
taglib
directive
include
directive
Implicit objects
Exception handling
Survey of other server-side Java technologies
XML
XSLT
Enterprise Java Beans
Java Messaging Service
Day 4: Databases, Best Practices, and Final Project
Databases and JDBC
Getting things set up
Connecting to the database
Load the driver
Create the connection
Statements
getXXX
methods
Updating the database
PreparedStatement
s
A real method
JUnit
Is Testing Important?
Mars Orbiter
USS Yorktown
Types of tests
Unit Testing 101
Definitions of unit testing
Goals of unit testing?
Unit Testing with JUnit
How to create unit tests with JUnit
A sample JUnit session
Recap
Best practices
Refactoring
Final project
Bibliography
Next:
Contents
Contents