Patterns in Java

10/21/98


Click here to start


Table of Contents

Patterns in Java

This presentation is based on a book...

These slides are at

Introduction

Structure of Patterns

Patterns in This Talk

Delegation (When Not to Use Inheritance)

Delegation: Synopsis

Delegation: Context

Delegation: Context (Cont..)

Inheritance to Model Roles

Delegation: Context (Cont..)

Combinations of Roles

Delegation: Context (Cont.)

Delegation to Model Roles

Delegation: Forces

Delegation: Forces (Cont.)

Solution: Use Delegation

Delegation: Consequences

Delegation: Related Patterns

Guarded Suspension

Guarded Suspension: Synopsis

Guarded Suspension: Context

Simple Queue Design

Guarded Suspension: Context (cont.)

Guarded Suspension: Context (cont.)

Guarded Suspension: Context (cont.)

Guarded Suspension: Context (cont.)

Guarded Suspension: Forces

Guarded Suspension: Solution

General Problem

Guarded Suspension: Solution (continued)

Guarded Suspension: Solution (continued)

General Solution

Guarded Suspension: Consequences

Nested Synchronization

Guarded Suspension: Implementation

Guarded Suspension Code

Guarded Suspension Code Continued

Patient Queue Code

Patient Queue Code (cont.)

Patient Queue Code (cont.)

Guarded Suspension: Related Patterns

Scheduler

Scheduler: Synopsis

Scheduler: Context

Security Journal Collaboration

The Sequencing Problem

The Sequencing Solution

Security Journal with Scheduler

Separate Sequencing from Scheduling

Scheduler: Solution

Scheduler Collaborations

Scheduler: Consequences

Code Example: Printer

Code Example: Scheduler

Code Example: Scheduler continued

Code Example: Scheduler continued

Code Example: Scheduler continued

Code Example: Scheduler continued

Code Example: Scheduler continued

Code Example: Scheduler continued

Code Example: Scheduler continued

Code Example: Scheduler continued

Code Example: Scheduler continued

Code Example: Scheduler continued

Scheduler: Related Patterns

Composite

Composite: Synopsis

Composite: Context

Composite: Context (cont.)

Composite: Context (cont.)

Composite: Context (cont.)

Composite: Forces

Composite: Solution

PPT Slide

Composite: Consequences

Composite: Consequences (continued)

Composite: Consequences (continued)

Composite: Consequences (continued)

Composite: Consequences (continued)

Composite: Implementation

Composite: Implementation (cont.)

Composite: Implementation (cont.)

Composite: Java API Usage

Composite: Java API Usage (continued)

Composite: Related Patterns

Chain of Responsibility

Chain of Responsibility: Synopsis

Chain of Responsibility: Context

Chain of Responsibility: Context (continued)

Chain of Responsibility: Context (continued)

Physical Security Object Organization

Chain of Responsibility: Forces

Chain of Responsibility: Solution

Chain of Responsibility: Consequences

Chain of Responsibility: Consequences (continued)

Chain of Responsibility: Implementation

Chain of Responsibility: Implementation

Chain of Responsibility: Implementation

Chain of Responsibility: JAVA API Usage

Chain of Responsibility: JAVA API Usage (cont.)

Chain of Responsibility: Related Patterns

Chain of Responsibility: Related Patterns (cont.)

The End (almost)

Help Wanted

Author: Mark D. Grand

Email: mgrand@mindspring.com

Home Page: http://www.mindspring.com/~mgrand