1 9 package org.jscience.physics.models; 10 11 import javax.measure.converters.RationalConverter; 12 import javax.measure.converters.UnitConverter; 13 import javax.measure.units.BaseUnit; 14 import javax.measure.units.Dimension; 15 import javax.measure.units.SI; 16 17 23 public final class QuantumModel extends PhysicalModel { 24 25 28 final static QuantumModel INSTANCE = new QuantumModel(); 29 32 private static RationalConverter METER_TO_TIME 33 = new RationalConverter(1, 299792458); 34 35 38 public static void select() { 39 throw new UnsupportedOperationException ("Not implemented"); 40 } 41 42 public Dimension getDimension(BaseUnit unit) { 44 if (unit.equals(SI.METER)) return Dimension.TIME; 45 return Dimension.Model.STANDARD.getDimension(unit); 46 } 47 48 public UnitConverter getTransform(BaseUnit unit) { 50 if (unit.equals(SI.METER)) return METER_TO_TIME; 51 return Dimension.Model.STANDARD.getTransform(unit); 52 } 53 54 77 } 78 | Popular Tags |