mondrian.util
Class UtilCompatibleJdk14
java.lang.Object
mondrian.util.UtilCompatibleJdk14
- All Implemented Interfaces:
- UtilCompatible
public class UtilCompatibleJdk14
- extends java.lang.Object
- implements UtilCompatible
Implementation of UtilCompatible
which runs in
JDK 1.4.
The code uses JDK 1.5 constructs such as generics and for-each loops,
but retroweaver can convert these. It does not use
java.util.EnumSet
, which is important, because retroweaver has
trouble with this.
- Since:
- Feb 5, 2007
- Version:
- $Id: //open/mondrian/src/main/mondrian/util/UtilCompatibleJdk14.java#7 $
- Author:
- jhyde
Method Summary |
<E extends java.lang.Enum<E>>
java.util.Set<E> |
|
enumSetAllOf(java.lang.Class<E> elementType)
|
<E extends java.lang.Enum<E>>
java.util.Set<E> |
|
enumSetNoneOf(java.lang.Class<E> elementType)
|
<E extends java.lang.Enum<E>>
java.util.Set<E> |
|
enumSetOf(E first,
E... rest)
|
|
getAnnotation(java.lang.reflect.Method method,
java.lang.String annotationClassName,
T defaultValue)
|
java.math.BigDecimal |
makeBigDecimalFromDouble(double d)
This generates a BigDecimal that can have a precision that does
not reflect the precision of the input double. |
java.lang.String |
quotePattern(java.lang.String s)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
UtilCompatibleJdk14
public UtilCompatibleJdk14()
enumSetOf
public <E extends java.lang.Enum<E>> java.util.Set<E> enumSetOf(E first,
E... rest)
- Specified by:
enumSetOf
in interface UtilCompatible
enumSetNoneOf
public <E extends java.lang.Enum<E>> java.util.Set<E> enumSetNoneOf(java.lang.Class<E> elementType)
- Specified by:
enumSetNoneOf
in interface UtilCompatible
enumSetAllOf
public <E extends java.lang.Enum<E>> java.util.Set<E> enumSetAllOf(java.lang.Class<E> elementType)
- Specified by:
enumSetAllOf
in interface UtilCompatible
makeBigDecimalFromDouble
public java.math.BigDecimal makeBigDecimalFromDouble(double d)
- This generates a BigDecimal that can have a precision that does
not reflect the precision of the input double.
- Specified by:
makeBigDecimalFromDouble
in interface UtilCompatible
- Parameters:
d
- input double
- Returns:
- BigDecimal
quotePattern
public java.lang.String quotePattern(java.lang.String s)
- Specified by:
quotePattern
in interface UtilCompatible
getAnnotation
public <T> T getAnnotation(java.lang.reflect.Method method,
java.lang.String annotationClassName,
T defaultValue)
- Specified by:
getAnnotation
in interface UtilCompatible