HttpResponse Class

  • java.lang.Object
    • com.microsoft.aad.msal4j.HttpResponse

Implements

public class HttpResponse
implements IHttpResponse

HTTP response

Constructor Summary

Constructor Description
HttpResponse()

Method Summary

Modifier and Type Method and Description
void addHeaders(Map<String,List<String>> responseHeaders)
java.lang.String body()

Gets the HTTP response body.

HttpResponse body(String body)
java.util.Map<java.lang.String,java.util.List<java.lang.String>> headers()

Gets the HTTP response headers.

int statusCode()

Gets the HTTP response status code.

HttpResponse statusCode(int statusCode)

Methods inherited from java.lang.Object

java.lang.Object.clone java.lang.Object.equals java.lang.Object.finalize java.lang.Object.getClass java.lang.Object.hashCode java.lang.Object.notify java.lang.Object.notifyAll java.lang.Object.toString java.lang.Object.wait java.lang.Object.wait java.lang.Object.wait

Constructor Details

HttpResponse

public HttpResponse()

Method Details

addHeaders

public void addHeaders(Map<String,List<String>> responseHeaders)

Parameters:

responseHeaders - Map of HTTP headers returned from HTTP client

body

public String body()

Gets the HTTP response body.

body

public HttpResponse body(String body)

Parameters:

body

headers

public Map<String,List<String>> headers()

Gets the HTTP response headers.

statusCode

public int statusCode()

Gets the HTTP response status code.

statusCode

public HttpResponse statusCode(int statusCode)

Parameters:

statusCode

Applies to