File tree Expand file tree Collapse file tree 1 file changed +15
-1
lines changed
src/main/java/com/arpnetworking/metrics/mad/model Expand file tree Collapse file tree 1 file changed +15
-1
lines changed Original file line number Diff line number Diff line change 21
21
*
22
22
* @author Ville Koskela (ville dot koskela at inscopemetrics dot io)
23
23
*/
24
- /* package private */ enum UnitType {
24
+ public enum UnitType {
25
+ /**
26
+ * Used in describing time durations.
27
+ */
25
28
TIME {
26
29
@ Override
27
30
public Unit getDefaultUnit () {
28
31
return Unit .SECOND ;
29
32
}
30
33
},
34
+ /**
35
+ * Used in describing data sizes.
36
+ */
31
37
DATA_SIZE {
32
38
@ Override
33
39
public Unit getDefaultUnit () {
34
40
return Unit .BYTE ;
35
41
}
36
42
},
43
+ /**
44
+ * Used in describing measurements of temperature.
45
+ */
37
46
TEMPERATURE {
38
47
@ Override
39
48
public Unit getDefaultUnit () {
40
49
return Unit .KELVIN ;
41
50
}
42
51
};
43
52
53
+ /**
54
+ * Get the default unit for this unit type. Used in normalizing values.
55
+ *
56
+ * @return The default unit for a given domain.
57
+ */
44
58
public abstract Unit getDefaultUnit ();
45
59
}
You can’t perform that action at this time.
0 commit comments