Class VidValidatorImpl

    • Constructor Detail

      • VidValidatorImpl

        public VidValidatorImpl()
    • Method Detail

      • validateId

        public boolean validateId​(String id)
        Method used for Validate VID against acceptance Criteria
        Specified by:
        validateId in interface VidValidator<String>
        Parameters:
        id - pass a VID in String format example : String inputFile = "426789089018"
        Returns:
        true if entered VID is valid
        Throws:
        InvalidIDException - If entered VID is empty or null.
        InvalidIDException - If entered VID contain any sequential and repeated block of number for 2 or more than two digits",
        InvalidIDException - If entered VID length should be specified number of digits.
        InvalidIDException - If entered VID contain any alphanumeric characters
        InvalidIDException - If entered VID should not match with checksum
        InvalidIDException - If entered VID contain Zero or One as first Digit.