The theory and practice of first-class prompts
POPL '88 Proceedings of the 15th ACM SIGPLAN-SIGACT symposium on Principles of programming languages
F-bounded polymorphism for object-oriented programming
FPCA '89 Proceedings of the fourth international conference on Functional programming languages and computer architecture
Design patterns: elements of reusable object-oriented software
Design patterns: elements of reusable object-oriented software
ECOOP '01 Proceedings of the 15th European Conference on Object-Oriented Programming
On the static and dynamic extents of delimited continuations
Science of Computer Programming
A framework for implementing pluggable type systems
Proceedings of the 21st annual ACM SIGPLAN conference on Object-oriented programming systems, languages, and applications
Adding delimited and composable control to a production programming environment
ICFP '07 Proceedings of the 12th ACM SIGPLAN international conference on Functional programming
Implementation and use of the PLT scheme Web server
Higher-Order and Symbolic Computation
Event-Based programming without inversion of control
JMLC'06 Proceedings of the 7th joint conference on Modular Programming Languages
Responders: language support for interactive applications
ECOOP'06 Proceedings of the 20th European conference on Object-Oriented Programming
Pattern matching for object-like structures in the Go programming language
Proceedings of the 6th Workshop on Implementation, Compilation, Optimization of Object-Oriented Languages, Programs and Systems
Hi-index | 0.00 |
The state design patternis the standard object-oriented programming idiom for implementing the state machine logic of interactive applications. While this pattern provides a number of advantages, it does not easily support the creation of extended state machines in subclasses. We describe the extensible state design pattern, which augments the traditional state pattern with a few additional constraints that allow subclasses to easily add both new states and new events. Further, we observe that delimited continuations, a well-known construct from functional programming languages, supports state refinementin subclasses as well as the modular expression of control flow in the presence of interaction. We illustrate our pattern in the context of Java, leveraging its generics to obviate the need for dynamic typecasts and employing a small library that implements delimited continuations. We have used our pattern to simplify and modularize a widely used application written by others.