Annotation Type VatId


  • @Documented
    @Constraint(validatedBy=VatIdValidator.class)
    @Target({TYPE,ANNOTATION_TYPE})
    @Retention(RUNTIME)
    public @interface VatId
    The annotated bean must contain two properties:
    • country code (option fieldCountryCode)
    • vat id (option fieldVatId)
    The vat id is checked against country specific rules for validity. Checksum checks are done, when available.
    Supported types are beans, null elements are considered valid.
    If allowLowerCaseCountryCode is set to true, lower case country codes are accepted.
    Author:
    Manfred Tremmel
    • Element Detail

      • message

        String message
        localized message.
        Returns:
        localized validation message
        Default:
        "{de.knightsoftnet.validators.shared.VatId.message}"
      • groups

        Class<?>[] groups
        groups to use.
        Returns:
        array of validation groups
        Default:
        {}
      • payload

        Class<? extends javax.validation.Payload>[] payload
        payload whatever.
        Returns:
        payload class
        Default:
        {}
      • fieldCountryCode

        String fieldCountryCode
        field name of the country code field.
        Returns:
        field/path contains country code
        Default:
        "countryCode"
      • allowLowerCaseCountryCode

        boolean allowLowerCaseCountryCode
        are lower case country codes allowed (true/false).
        Returns:
        true if lower case country code is allowed
        Default:
        false
      • fieldVatId

        String fieldVatId
        field name of the vat id field.
        Returns:
        field/path contains vat id
        Default:
        "vatId"