Class: SimResponse

SimResponse()

Class representing a request to the HTTP endpoint Similar to Response in Express or SparkJava no methods, just public members

Constructor

new SimResponse()

Methods

send(data)

The data to return to the caller as a String or Object
Parameters:
Name Type Description
data String | Object
Returns:
this Response object for chaining

status(val)

Set the HTTP Status 200,201,400 etc.
Parameters:
Name Type Description
val number HTTP Status code
Returns:
this SimResponse object to allow chaining