public static class **DnsOptions.StaleDnsOptions** extends Object  
A class configuring Cronet's stale DNS functionality.

DNS resolution is one of the steps on the critical path to making a URL request, but it
can be slow for various reasons (underlying network latency, buffer bloat, packet loss,
etc.).

Depending on the use case, it might be worthwhile for an app developer to trade off
guaranteed DNS record freshness for better availability of DNS records.

Stale results can include both:

- results returned from the current network's DNS server, but past their time-to-live, and
- results returned from a previous network's DNS server, whether expired or not.

<br />

### Nested Class Summary

|-------|---|---|-----------------------------------------------------------------------------------------------------------------------------------------------------------------|
| class | [DnsOptions.StaleDnsOptions.Builder](https://developer.android.com/develop/connectivity/cronet/reference/org/chromium/net/DnsOptions.StaleDnsOptions.Builder.html) || Builder for [DnsOptions.StaleDnsOptions](https://developer.android.com/develop/connectivity/cronet/reference/org/chromium/net/DnsOptions.StaleDnsOptions.html). |

### Public Method Summary

|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| static [DnsOptions.StaleDnsOptions.Builder](https://developer.android.com/develop/connectivity/cronet/reference/org/chromium/net/DnsOptions.StaleDnsOptions.Builder.html) | [builder](https://developer.android.com/develop/connectivity/cronet/reference/org/chromium/net/DnsOptions.StaleDnsOptions.html#builder())()                                           |
| Boolean                                                                                                                                                                   | [getAllowCrossNetworkUsage](https://developer.android.com/develop/connectivity/cronet/reference/org/chromium/net/DnsOptions.StaleDnsOptions.html#getAllowCrossNetworkUsage())()       |
| Long                                                                                                                                                                      | [getFreshLookupTimeoutMillis](https://developer.android.com/develop/connectivity/cronet/reference/org/chromium/net/DnsOptions.StaleDnsOptions.html#getFreshLookupTimeoutMillis())()   |
| Long                                                                                                                                                                      | [getMaxExpiredDelayMillis](https://developer.android.com/develop/connectivity/cronet/reference/org/chromium/net/DnsOptions.StaleDnsOptions.html#getMaxExpiredDelayMillis())()         |
| Boolean                                                                                                                                                                   | [getUseStaleOnNameNotResolved](https://developer.android.com/develop/connectivity/cronet/reference/org/chromium/net/DnsOptions.StaleDnsOptions.html#getUseStaleOnNameNotResolved())() |

### Inherited Method Summary

From class java.lang.Object  

|------------------|---------------------------|
| Object           | clone()                   |
| boolean          | equals(Object arg0)       |
| void             | finalize()                |
| final Class\<?\> | getClass()                |
| int              | hashCode()                |
| final void       | notify()                  |
| final void       | notifyAll()               |
| String           | toString()                |
| final void       | wait(long arg0, int arg1) |
| final void       | wait(long arg0)           |
| final void       | wait()                    |

## Public Methods

#### public static [DnsOptions.StaleDnsOptions.Builder](https://developer.android.com/develop/connectivity/cronet/reference/org/chromium/net/DnsOptions.StaleDnsOptions.Builder.html)
**builder**
()

<br />

#### public Boolean
**getAllowCrossNetworkUsage**
()

<br />

#### public Long
**getFreshLookupTimeoutMillis**
()

<br />

#### public Long
**getMaxExpiredDelayMillis**
()

<br />

#### public Boolean
**getUseStaleOnNameNotResolved**
()

<br />