Package org.cyclos.impl
Interface BigDecimalScaleHandler
-
public interface BigDecimalScaleHandlerHandles resolution ofBigDecimalscale
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidadjustScale(Object object)Adjusts the scale of allBigDecimalandDecimalRangefields of the given entity and any of itsEmbeddablesBigDecimaladjustScale(Object object, Object field, BigDecimal value)Returns an ajustedBigDecimalaccording to the rule for the given object and field.voidadjustScale(Object object, Object field, DecimalRange range)Adjusts a decimal range with correct scales.intgetScale(Object object, Object field)Returns the scale of a field by name of the given object, or -1 if not a valid field.BigDecimalgetWithAdjustedScale(Object object, Object field)Returns an ajustedBigDecimalaccording to the rule for the given object and field, getting the field value by reflection.
-
-
-
Method Detail
-
adjustScale
void adjustScale(Object object)
Adjusts the scale of allBigDecimalandDecimalRangefields of the given entity and any of itsEmbeddables
-
adjustScale
BigDecimal adjustScale(Object object, Object field, BigDecimal value)
Returns an ajustedBigDecimalaccording to the rule for the given object and field. The field may be a String, aPropertyor aPath.
-
adjustScale
void adjustScale(Object object, Object field, DecimalRange range)
Adjusts a decimal range with correct scales. SeeadjustScale(Object, Object, BigDecimal)
-
getScale
int getScale(Object object, Object field)
Returns the scale of a field by name of the given object, or -1 if not a valid field. The field may be a String, aPropertyor aPath.
-
getWithAdjustedScale
BigDecimal getWithAdjustedScale(Object object, Object field)
Returns an ajustedBigDecimalaccording to the rule for the given object and field, getting the field value by reflection. The field may be a String, aPropertyor aPath.
-
-