Uploaded image for project: 'Commons Validator'
  1. Commons Validator
  2. VALIDATOR-444

LongValidator: numbers bigger than the maxvalue are Valid

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 1.6
    • 1.7
    • Routines
    • None

    Description

      If you try to validate a Value bigger than 9,223,372,036,854,775,807 it keeps valid.

        for example with:

      LongValidator longValidator = new LongValidator ( true, AbstractNumberValidator.STANDARD_FORMAT );
      longValidator.isValid("9223372036854775808") // is true should be false max long is 9223372036854775807
      

      even worse is that:

       

      longValidator.validate ( "9999999999999999999999999999999999999")
      

      will give you the long maxValue as Result.

      The IntegerValidator will give you null and nonValid. 

       

      Attachments

        Activity

          People

            Unassigned Unassigned
            wurtzelsepp Martin Scholz
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: