Generalize for non-address results in HostResolverImpl

Now extensively using HostCache::Entry internally (but only internally
to preserve flexibility of HostCache) as a generalized results
container within HostResolverImpl. Added some needed setter/merge
functionality to Entry for that purpose.  Many methods within the
resolver changed to use Entry for consistency even if they only ever
deal with address results, eg ResolveAsIP().

Slightly modified results port-setting functionality to only set port
to an input port (from |host.port()|) if the port in the results is 0
(where before it would set it whenever it wasn't equal to the input
port).  This will be necessary eg for SRV support where DNS provides a
specific port that needs to be maintained in the results. Also cleaned
up the port setting to consistently only ever happen just before
setting results on the RequestImpl and having 0 or a DNS-provided port
until then.

Bug: 846423
Change-Id: I679c0ac915e0f81b49adb5ee769f250be49c9c90
Reviewed-on: https://chromium-review.googlesource.com/c/1340835
Reviewed-by: Matt Menke <[email protected]>
Commit-Queue: Eric Orth <[email protected]>
Cr-Commit-Position: refs/heads/master@{#611963}
11 files changed