1 package org.opentrafficsim.core.unit;
2
3 import static org.opentrafficsim.core.unit.unitsystem.UnitSystem.OTHER;
4 import static org.opentrafficsim.core.unit.unitsystem.UnitSystem.SI_ACCEPTED;
5 import static org.opentrafficsim.core.unit.unitsystem.UnitSystem.SI_DERIVED;
6
7 import org.opentrafficsim.core.unit.unitsystem.UnitSystem;
8
9
10
11
12
13
14
15
16
17
18
19 public class AngleSlopeUnit extends Unit<AngleSlopeUnit>
20 {
21
22 private static final long serialVersionUID = 20140607L;
23
24
25 public static final AngleSlopeUnit SI;
26
27
28 public static final AngleSlopeUnit RADIAN;
29
30
31
32
33
34
35 public static final AngleSlopeUnit DEGREE;
36
37
38 public static final AngleSlopeUnit ARCMINUTE;
39
40
41 public static final AngleSlopeUnit ARCSECOND;
42
43
44 public static final AngleSlopeUnit GRAD;
45
46
47 public static final AngleSlopeUnit CENTESIMAL_ARCMINUTE;
48
49
50 public static final AngleSlopeUnit CENTESIMAL_ARCSECOND;
51
52 static
53 {
54 SI = new AngleSlopeUnit("AngleSlopeUnit.radian", "AngleSlopeUnit.rad", SI_DERIVED);
55 RADIAN = SI;
56 DEGREE =
57 new AngleSlopeUnit("AngleSlopeUnit.degree", "AngleSlopeUnit.deg", SI_ACCEPTED, RADIAN, Math.PI / 180.0);
58 ARCMINUTE =
59 new AngleSlopeUnit("AngleSlopeUnit.arcminute", "AngleSlopeUnit.arcmin", SI_ACCEPTED, DEGREE, 1.0 / 60.0);
60 ARCSECOND =
61 new AngleSlopeUnit("AngleSlopeUnit.arcsecond", "AngleSlopeUnit.arcsec", SI_ACCEPTED, DEGREE,
62 1.0 / 3600.0);
63 GRAD =
64 new AngleSlopeUnit("AngleSlopeUnit.gradian", "AngleSlopeUnit.grad", OTHER, RADIAN,
65 2.0 * Math.PI / 400.0);
66 CENTESIMAL_ARCMINUTE =
67 new AngleSlopeUnit("AngleSlopeUnit.centesimal_arcminute", "AngleSlopeUnit.centesimal_arcmin", OTHER,
68 GRAD, 1.0 / 100.0);
69 CENTESIMAL_ARCSECOND =
70 new AngleSlopeUnit("AngleSlopeUnit.centesimal_arcsecond", "AngleSlopeUnit.centesimal_arcsec", OTHER,
71 GRAD, 1.0 / 10000.0);
72 }
73
74
75
76
77
78
79
80 public AngleSlopeUnit(final String nameKey, final String abbreviationKey, final UnitSystem unitSystem)
81 {
82 super(nameKey, abbreviationKey, unitSystem, true);
83 }
84
85
86
87
88
89
90
91
92
93
94 public AngleSlopeUnit(final String nameKey, final String abbreviationKey, final UnitSystem unitSystem,
95 final AngleSlopeUnit referenceUnit, final double conversionFactorToReferenceUnit)
96 {
97 super(nameKey, abbreviationKey, unitSystem, referenceUnit, conversionFactorToReferenceUnit, true);
98 }
99
100
101 @Override
102 public final AngleSlopeUnit getStandardUnit()
103 {
104 return RADIAN;
105 }
106
107
108 @Override
109 public final String getSICoefficientsString()
110 {
111 return "";
112 }
113
114 }