Added in API level 34
Also in S Extensions 7

HttpException


public class HttpException
extends IOException

java.lang.Object
   ↳ java.lang.Throwable
     ↳ java.lang.Exception
       ↳ java.io.IOException
         ↳ android.net.http.HttpException


Base exception passed to UrlRequest.Callback.onFailed().

Summary

Public constructors

HttpException(String message, Throwable cause)

Constructs an exception that is caused by cause.

Inherited methods

Public constructors

HttpException

Added in API level 34
Also in S Extensions 7
public HttpException (String message, 
                Throwable cause)

Constructs an exception that is caused by cause.

Parameters
message String: explanation of failure. This value may be null.

cause Throwable: the cause (which is saved for later retrieval by the getCause() method). A null value is permitted, and indicates that the cause is nonexistent or unknown.