public class Ratio extends Object implements groovy.lang.GroovyObject
| Constructor and Description |
|---|
Ratio(int numerator,
int denominator) |
| Modifier and Type | Method and Description |
|---|---|
Object |
asType(Class theClass) |
int |
getDenominator() |
groovy.lang.MetaClass |
getMetaClass() |
int |
getNumerator() |
Object |
getProperty(String property) |
Object |
invokeMethod(String method,
Object arguments) |
Ratio |
plus(Ratio ratio) |
void |
setMetaClass(groovy.lang.MetaClass mc) |
void |
setProperty(String property,
Object value) |
BigDecimal |
toBigDecimal(int scale,
int roundingMode) |
String |
toString() |
public static Object ZERO
public groovy.lang.MetaClass getMetaClass()
getMetaClass in interface groovy.lang.GroovyObjectpublic void setMetaClass(groovy.lang.MetaClass mc)
setMetaClass in interface groovy.lang.GroovyObjectpublic Object invokeMethod(String method, Object arguments)
invokeMethod in interface groovy.lang.GroovyObjectpublic Object getProperty(String property)
getProperty in interface groovy.lang.GroovyObjectpublic void setProperty(String property, Object value)
setProperty in interface groovy.lang.GroovyObjectpublic int getNumerator()
public int getDenominator()
public BigDecimal toBigDecimal(int scale,
int roundingMode)
Copyright © 2015. All rights reserved.