Package com.ngrok.services
Class HttpResponseBackends.CreateCallBuilder
java.lang.Object
com.ngrok.services.HttpResponseBackends.CreateCallBuilder
- Enclosing class:
- HttpResponseBackends
A builder object encapsulating state for an unsent Create API call.
-
Method Summary
Modifier and TypeMethodDescriptionInitiates the API call and blocks until it returns.body to return as fixed contentbody to return as fixed contentcall()
Initiates the API call asynchronously.description
(String description) human-readable description of this backend.description
(Optional<String> description) human-readable description of this backend.headers to returnheaders to returnarbitrary user-defined machine-readable data of this backend.arbitrary user-defined machine-readable data of this backend.statusCode
(int statusCode) status code to returnstatusCode
(Optional<Integer> statusCode) status code to return
-
Method Details
-
description
human-readable description of this backend. Optional- Parameters:
description
- the value of the description parameter as aString
- Returns:
- the call builder instance
-
description
human-readable description of this backend. Optional -
metadata
arbitrary user-defined machine-readable data of this backend. Optional- Parameters:
metadata
- the value of the metadata parameter as aString
- Returns:
- the call builder instance
-
metadata
arbitrary user-defined machine-readable data of this backend. Optional -
body
body to return as fixed content- Parameters:
body
- the value of the body parameter as aString
- Returns:
- the call builder instance
-
body
body to return as fixed content -
headers
headers to return -
headers
headers to return -
statusCode
status code to return- Parameters:
statusCode
- the value of the status_code parameter as aint
- Returns:
- the call builder instance
-
statusCode
status code to return- Parameters:
statusCode
- the value of the status_code parameter as anOptional
ofint
- Returns:
- the call builder instance
-
call
Initiates the API call asynchronously.- Returns:
- a
CompletionStage
ofHttpResponseBackend
-
blockingCall
Initiates the API call and blocks until it returns.- Returns:
HttpResponseBackend
- Throws:
InterruptedException
- if the thread was interrupted during the call
-