Java BigDecimal Value Check isLongNumber(BigDecimal minCar)

Here you can find the source of isLongNumber(BigDecimal minCar)

Description

is Long Number

License

Open Source License

Declaration

public static boolean isLongNumber(BigDecimal minCar) 

Method Source Code


//package com.java2s;
/*//w w w. j  a va  2  s.  co  m
 * Copyright (C) 2010 Viettel Telecom. All rights reserved.
 * VIETTEL PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
 */

import java.math.BigDecimal;

public class Main {
    public static boolean isLongNumber(BigDecimal minCar) {
        try {
            Long.parseLong(minCar.toString());
            return true;
        } catch (Exception ex) {
            return false;
        }
    }
}

Related

  1. isJavaMathBigDecimal(Object value)
  2. isLessOrEqualThanZero(BigDecimal value)
  3. isLessThan(final BigDecimal thiss, final BigDecimal that)
  4. isLessThen(BigDecimal value1, BigDecimal value2)
  5. isLong(BigDecimal inValue)
  6. isLowerThanOne(@Nonnull final BigDecimal aValue)
  7. isMaximumDecimalValue(BigDecimal maxValue)
  8. isMoreThanZero(BigDecimal decimal)
  9. isNegative(BigDecimal amount)