Uploaded image for project: 'Hibernate Validator'
  1. HV-925

Implement rules for automatic value unwrapping

    Details

    • Type: Task
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 5.2.0.Alpha1
    • Component/s: engine
    • Labels:
    • Last commented by a user?:
      true
    • Sprint:

      Description

      The rules have been discussed here.

      Validator exists for wrapper Validator exists for wrapped value Unwrapper exists Example Desirable result
      1 Declaration error
      2 x @Future Optional<Integer> myInt; Declaration error
      3 x @Min(3) Holder<Integer> myHolder; Declaration error
      4 x x @Min(3) Optional<nteger> myInt; Optional<@Email String>; Validate wrapped value
      5 x @ValidHolder Holder myHolder; Validate wrapper
      6 x x @ValidHolder Holder myHolder; Validate wrapper
      7 x x @NotNull Holder myHolder; Validate wrapper
      8 x x x @NotNull IntegerProperty myInt; Declaration error; needs to be resolved by making intent explicit (which could be achieved by adding a boolean flag to @UnwrapValidatedValue)

        Attachments

          Issue links

            Activity

              People

              • Assignee:
                hardy.ferentschik Hardy Ferentschik
                Reporter:
                hardy.ferentschik Hardy Ferentschik
                Participants:
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: