Refactor legacy domain verification code
Moves everything to com.android.server.pm.intent.verify.legacy, in
preparation for replacement with new classes.
No functional changes were made, although the code may be slightly
slower since lambdas are now passed around to do locking.
Eventually the entire legacy package will be deleted. Any attempts at
backwards compatbility will involve a brand new wrapper of the v1 APIs
which delegate into the v2 methods.
Exempt-From-Owner-Approval: Already approved by owners on main branch
Bug: 163565078
Test: atest IntentFilterVerificationTest
Test: manual, verify with `dumpsys package d` that an app auto verifies
Change-Id: Id7d428b939cab6dd887567abcc7ba0e8f3fb7638
13 files changed