/* GENERATED SOURCE. DO NOT MODIFY. */ /* * Copyright (C) 2012 Square, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.android.okhttp; import java.net.InetAddress; import java.net.UnknownHostException; import java.util.Arrays; import java.util.List; /** * A domain name service that resolves IP addresses for host names. Most applications will use the * {@linkplain #SYSTEM system DNS service}, which is the default. Some applications may provide * their own implementation to use a different DNS server, to prefer IPv6 addresses, to prefer IPv4 * addresses, or to force a specific known IP address. * *
Implementations of this interface must be safe for concurrent use.
* @hide This class is not part of the Android public SDK API
*/
public interface Dns {
/**
* A DNS that uses {@link InetAddress#getAllByName} to ask the underlying operating system to
* lookup IP addresses. Most custom {@link Dns} implementations should delegate to this instance.
*/
Dns SYSTEM = new Dns() {
@Override public List