Class SINValidator

java.lang.Object
org.apache.commons.validator.routines.SINValidator

public class SINValidator extends Object
SIN (Canadian social insurance number) Validator.

The social insurance number (SIN) is a unique identifier and has become a national identification number, see Wikipedia.

Since:
2.10.6
Author:
EUG https://github.com/homebeaver
  • Constructor Details

    • SINValidator

      public SINValidator()
  • Method Details

    • getInstance

      public static SINValidator getInstance()
      Return a singleton instance of the validator using the default formats
      Returns:
      A singleton instance of the validator
    • isValid

      public boolean isValid(String code)
      Validate a SIN
      Parameters:
      code - The value validation is being performed on
      Returns:
      true if the value is valid