JavaUI: Effects for controlling UI object access

Download: PDF, slides (PDF), technical report (PDF), JavaUI implementation, older implementation and annotated subject programs.

“JavaUI: Effects for controlling UI object access” by Colin S. Gordon, Werner Dietl, Michael D. Ernst, and Dan Grossman. In ECOOP 2013 — Object-Oriented Programming, 27th European Conference, (Montpellier, France), July 2013, pp. 179-204.
A previous version appeared as “JavaUI: Effects for controlling UI object access (extended version)” by Colin S. Gordon, Werner Dietl, Michael D. Ernst, and Dan Grossman. University of Washington Department of Computer Science and Engineering technical report UW-CSE-13-04-01, (Seattle, WA, USA), Apr. 2013.

Abstract

Most graphical user interface (GUI) libraries forbid accessing UI elements from threads other than the UI event loop thread. Violating this requirement leads to a program crash or an inconsistent UI. Unfortunately, such errors are all too common in GUI programs.

We present a polymorphic type and effect system that prevents non-UI threads from accessing UI objects or invoking UI-thread-only methods. The type system still permits non-UI threads to hold and pass references to UI objects. We implemented this type system for Java and annotated 8 Java programs (over 140KLOC) for the type system, including several of the most popular Eclipse plugins. We confirmed bugs found by unsound prior work, found an additional bug and code smells, and demonstrated that the annotation burden is low.

We also describe code patterns our effect system handles less gracefully or not at all, which we believe offers lessons for those applying other effect systems to existing code.

Download: PDF, slides (PDF), technical report (PDF), JavaUI implementation, older implementation and annotated subject programs.

BibTeX entry:

@inproceedings{GordonDEG2013,
   author = {Colin S. Gordon and Werner Dietl and Michael D. Ernst and Dan
	Grossman},
   title = {{JavaUI}: Effects for controlling {UI} object access},
   booktitle = {ECOOP 2013 --- Object-Oriented Programming, 27th European
	Conference},
   pages = {179--204},
   address = {Montpellier, France},
   month = jul,
   year = {2013}
}

(This webpage was created with bibtex2web.)

Back to Michael Ernst's publications.