Package com.inet.report.chart.format
Class Abbreviation
- java.lang.Object
-
- com.inet.report.chart.format.Abbreviation
-
- All Implemented Interfaces:
java.io.Serializable
public class Abbreviation extends java.lang.Object implements java.io.Serializable
This class represents an abbreviation instance. There are four abbreviations available: thousand (K), million (M), billion (B) and none. The abbreviation divides the value and writes the abbreviation symbol after this value in a chart. TheABBREVIATION_NONE
can be used to reset the abbreviation.- Since:
- 8.0
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static Abbreviation
ABBREVIATION_BILLIONS
Billions abbreviationstatic Abbreviation
ABBREVIATION_MILLIONS
Millions abbreviationstatic Abbreviation
ABBREVIATION_NONE
None abbreviationstatic Abbreviation
ABBREVIATION_THOUSANDS
Thousands abbreviation
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object object)
static Abbreviation
getAbbreviation(org.w3c.dom.Element element)
Reads the XML properties of a abbreviation.double
getDivisor()
Returns the divisor.java.lang.String
getSymbol()
Returns the symbol for this abbreviation, e.g.int
hashCode()
-
-
-
Field Detail
-
ABBREVIATION_NONE
public static final Abbreviation ABBREVIATION_NONE
None abbreviation
-
ABBREVIATION_THOUSANDS
public static final Abbreviation ABBREVIATION_THOUSANDS
Thousands abbreviation
-
ABBREVIATION_MILLIONS
public static final Abbreviation ABBREVIATION_MILLIONS
Millions abbreviation
-
ABBREVIATION_BILLIONS
public static final Abbreviation ABBREVIATION_BILLIONS
Billions abbreviation
-
-
Method Detail
-
getDivisor
public double getDivisor()
Returns the divisor. The divisor forABBREVIATION_THOUSANDS
is 1000.- Returns:
- the divisor.
- Since:
- 8.0
-
getSymbol
public java.lang.String getSymbol()
Returns the symbol for this abbreviation, e.g. 'K' for thousand.- Returns:
- the symbol string.
- Since:
- 8.0
-
equals
public boolean equals(java.lang.Object object)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
getAbbreviation
public static Abbreviation getAbbreviation(org.w3c.dom.Element element)
Reads the XML properties of a abbreviation.- Parameters:
element
- the DOM element- Returns:
- the new abbreviation.
- Since:
- 8.0
- See Also:
Abbreviation
,Element
-
-