class NumberFieldActions implements AtlasFieldAction {

    @AtlasActionProcessor
    public static Number minimum(Minimum minimum, List<Number> inputs) {
        if (inputs == null) {
            return 0;
        }

        Number min = null;
        for (Object entry : inputs) {
            if (entry instanceof Number) {
                if (min instanceof BigDecimal && entry instanceof BigDecimal) {
                    min = ((BigDecimal) entry).min((BigDecimal)min);
                } else if (min == null || ((Number) entry).doubleValue() < min.doubleValue()) {
                    min = (Number) entry;
                }
            } else {
                warnIgnoringValue("Minimum", entry);
            }
        }

        return min;
    }

}