1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19 package org.kuali.coeus.sys.api.model;
20
21 import java.math.BigDecimal;
22
23
24
25
26
27
28
29
30
31
32
33 public final class ScaleThreeDecimal extends AbstractDecimal<ScaleThreeDecimal> {
34
35 private static final long serialVersionUID = -1132481837308782665L;
36
37 public static final int SCALE = 3;
38
39 public static final ScaleThreeDecimal ZERO = new ScaleThreeDecimal(0.000);
40 public static final ScaleThreeDecimal ONE_HUNDRED = new ScaleThreeDecimal(100);
41
42
43
44
45 private ScaleThreeDecimal() {
46 super();
47 }
48
49 public ScaleThreeDecimal(String value) {
50 super(value, SCALE);
51 }
52
53 public ScaleThreeDecimal(int value) {
54 super(value, SCALE);
55 }
56
57 public ScaleThreeDecimal(double value) {
58 super(value, SCALE);
59 }
60
61 public ScaleThreeDecimal(BigDecimal value) {
62 super(value, SCALE);
63 }
64
65 private ScaleThreeDecimal(String value, int scale) {
66 super(value, scale);
67 }
68
69 private ScaleThreeDecimal(int value, int scale) {
70 super(value, scale);
71 }
72
73 private ScaleThreeDecimal(double value, int scale) {
74 super(value, scale);
75 }
76
77 private ScaleThreeDecimal(BigDecimal value, int scale) {
78 super(value, scale);
79 }
80
81 @Override
82 protected ScaleThreeDecimal newInstance(int value) {
83 return new ScaleThreeDecimal(value);
84 }
85
86 @Override
87 protected ScaleThreeDecimal newInstance(BigDecimal value, int scale) {
88 return new ScaleThreeDecimal(value, scale);
89 }
90
91 @Override
92 protected ScaleThreeDecimal zero() {
93 return ZERO;
94 }
95
96 @Override
97 protected ScaleThreeDecimal oneHundred() {return ONE_HUNDRED; }
98 }