KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > tonbeller > jpivot > olap > model > impl > NumberFormatImpl


1 /*
2  * ====================================================================
3  * This software is subject to the terms of the Common Public License
4  * Agreement, available at the following URL:
5  * http://www.opensource.org/licenses/cpl.html .
6  * Copyright (C) 2003-2004 TONBELLER AG.
7  * All Rights Reserved.
8  * You must accept the terms of that agreement to use this software.
9  * ====================================================================
10  *
11  *
12  */

13 /**
14  * Created on 24.03.2003
15  */

16 package com.tonbeller.jpivot.olap.model.impl;
17
18 import com.tonbeller.jpivot.olap.model.NumberFormat;
19
20 /**
21  * @author av
22  */

23 public class NumberFormatImpl implements NumberFormat {
24   boolean grouping = true;
25   int fractionDigits = 2;
26   boolean percent = false;
27   
28   /**
29    * @return int
30    */

31   public int getFractionDigits() {
32     return fractionDigits;
33   }
34
35   /**
36    * @return boolean
37    */

38   public boolean isGrouping() {
39     return grouping;
40   }
41
42   /**
43    * Sets the fractionDigits.
44    * @param fractionDigits The fractionDigits to set
45    */

46   public void setFractionDigits(int fractionDigits) {
47     this.fractionDigits = fractionDigits;
48   }
49
50   /**
51    * Sets the grouping.
52    * @param grouping The grouping to set
53    */

54   public void setGrouping(boolean grouping) {
55     this.grouping = grouping;
56   }
57
58   /**
59    * @see com.tonbeller.jpivot.olap.model.NumberFormat#isPercent()
60    */

61   public boolean isPercent() {
62     return percent;
63   }
64
65 }
66
Popular Tags