View Javadoc
1   /*
2    * Licensed to the Apache Software Foundation (ASF) under one or more
3    * contributor license agreements.  See the NOTICE file distributed with
4    * this work for additional information regarding copyright ownership.
5    * The ASF licenses this file to You under the Apache License, Version 2.0
6    * (the "License"); you may not use this file except in compliance with
7    * the License.  You may obtain a copy of the License at
8    *
9    *      https://www.apache.org/licenses/LICENSE-2.0
10   *
11   * Unless required by applicable law or agreed to in writing, software
12   * distributed under the License is distributed on an "AS IS" BASIS,
13   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14   * See the License for the specific language governing permissions and
15   * limitations under the License.
16   */
17  
18  /*
19   * This is not the original file distributed by the Apache Software Foundation
20   * It has been modified by the Hipparchus project
21   */
22  
23  package org.hipparchus.dfp;
24  
25  public class Decimal10 extends DfpDec {
26  
27      Decimal10(final DfpField factory) {
28          super(factory);
29      }
30  
31      Decimal10(final DfpField factory, final byte x) {
32          super(factory, x);
33      }
34  
35      Decimal10(final DfpField factory, final int x) {
36          super(factory, x);
37      }
38  
39      Decimal10(final DfpField factory, final long x) {
40          super(factory, x);
41      }
42  
43      Decimal10(final DfpField factory, final double x) {
44          super(factory, x);
45      }
46  
47      public Decimal10(final Dfp d) {
48          super(d);
49      }
50  
51      public Decimal10(final DfpField factory, final String s) {
52          super(factory, s);
53      }
54  
55      protected Decimal10(final DfpField factory, final byte sign, final byte nans) {
56          super(factory, sign, nans);
57      }
58  
59      @Override
60      public Dfp newInstance() {
61          return new Decimal10(getField());
62      }
63  
64      @Override
65      public Dfp newInstance(final byte x) {
66          return new Decimal10(getField(), x);
67      }
68  
69      @Override
70      public Dfp newInstance(final int x) {
71          return new Decimal10(getField(), x);
72      }
73  
74      @Override
75      public Dfp newInstance(final long x) {
76          return new Decimal10(getField(), x);
77      }
78  
79      @Override
80      public Dfp newInstance(final double x) {
81          return new Decimal10(getField(), x);
82      }
83  
84      @Override
85      public Dfp newInstance(final Dfp d) {
86          return new Decimal10(d);
87      }
88  
89      @Override
90      public Dfp newInstance(final String s) {
91          return new Decimal10(getField(), s);
92      }
93  
94      @Override
95      public Dfp newInstance(final byte sign, final byte nans) {
96          return new Decimal10(getField(), sign, nans);
97      }
98  
99      @Override
100     protected int getDecimalDigits() {
101         return 10;
102     }
103 
104 }