• sebsg's avatar
    [Autofill] Refactor Profile Validation API · 774453da
    sebsg authored
    Changes the callback return value of the API to be a pointer to
    the profile instead of being the validity state of the profile.
    
    The concept of a validity state for the whole profile was removed since
    validity depends on the context (Autofill != Payment Request).
    
    Using a pointer to the validated profile is more useful for the called,
    which can now start the validation of all profiles at the same time and
    handle the result from the callback.
    
    Another modification was to put all of the validation utils in the same
    file.
    
    Also make the validator keep a weakptr to an AutofillProfile in case
    it gets deleted while loading the rules.
    
    Bug: 
    Change-Id: I9d41a0cea577351d8a1618bc9f771af1524e38c6
    Reviewed-on: https://chromium-review.googlesource.com/709779
    Commit-Queue: Sebastien Seguin-Gagnon <sebsg@chromium.org>
    Reviewed-by: default avatarRoger McFarlane <rogerm@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#516344}
    774453da
BUILD.gn 14.1 KB