Eclipse UOMo
Eclipse Juno Demo Camp
Manchester, UK
What is it?
Units of Measurement API
Avoiding Interface�and Arithmetic Errors
The Goal
© 2007-2011 Creative Arts & Technologies
Emphasis
Most of today’s technologies including the Java Language so far lack support for common non-trivial Arithmetic problems like Unit Conversions
© 2007-2011 Creative Arts & Technologies
What do these disasters have in common?
© 2007-2011 Creative Arts & Technologies
What do these disasters have in common?
© 2007-2011 Creative Arts & Technologies
NASA “Star Wars” Initiative, 1983
23rd March 1983. Ronald Reagan announces SDI (or “Star Wars”): ground-based and space-based systems to protect the US from attack by strategic nuclear ballistic missiles.
1985
Mirror on underside of shuttle
SDI Experiment: The Plan
Big mountain in Hawaii
1985
SDI Experiment: What really happened
1985: What happened?
Unit Tests wouldn‘t find these…
© 2007-2011 Creative Arts & Technologies
Causes of Conversion Errors
static final double PIXEL_TO_INCH = 1 / 72;
double pixels = inches * PIXEL_TO_INCH
© 2007-2011 Creative Arts & Technologies
Eclipse UOMo
One Small Step…
Eclipse UOMo
© 2007-2011 Creative Arts & Technologies
One Unit Framework to Measure them All
Eclipse UOMo
© 2007-2011 Creative Arts & Technologies
Bundles
Eclipse UOMo
© 2007-2011 Creative Arts & Technologies
Bundles (2)
UOMo: UCUM
© 2007-2011 Creative Arts & Technologies
Unified Code for Units of Measure
UOMo: UCUM Examples
© 2007-2011 Creative Arts & Technologies
UCUM String | Human Unit | Quantity |
m/s | Meter per second | Length |
% | Percent | None |
[tbs_us] | Tablespoon (US) | Volume |
mm2 | Square Millimeter | Area |
mL/kg/h | Millilitre per Kilogram per hour | Dose |
cm[H2O]/(s.m) | Centimeter H20 per second and meter | Pulmonary pressure time product |
DEMO
Eclipse UOMo
Links
Q & A
Let‘s talk
Contact