@Generated(value="jsii-pacmak/1.67.0 (build 2c027f5)", date="2022-09-19T20:26:39.116Z") @Stability(value=Stable) public interface FixedResponseOptions extends software.amazon.jsii.JsiiSerializable
Example:
ApplicationListener listener;
listener.addAction("Fixed", AddApplicationActionProps.builder()
.priority(10)
.conditions(List.of(ListenerCondition.pathPatterns(List.of("/ok"))))
.action(ListenerAction.fixedResponse(200, FixedResponseOptions.builder()
.contentType(ContentType.TEXT_PLAIN)
.messageBody("OK")
.build()))
.build());
| Modifier and Type | Interface and Description |
|---|---|
static class |
FixedResponseOptions.Builder
A builder for
FixedResponseOptions |
static class |
FixedResponseOptions.Jsii$Proxy
An implementation for
FixedResponseOptions |
| Modifier and Type | Method and Description |
|---|---|
static FixedResponseOptions.Builder |
builder() |
default String |
getContentType()
Content Type of the response.
|
default String |
getMessageBody()
The response body.
|
@Stability(value=Stable) @Nullable default String getContentType()
Valid Values: text/plain | text/css | text/html | application/javascript | application/json
Default: - Automatically determined
@Stability(value=Stable) @Nullable default String getMessageBody()
Default: - No body
@Stability(value=Stable) static FixedResponseOptions.Builder builder()
FixedResponseOptions.Builder of FixedResponseOptionsCopyright © 2022. All rights reserved.