Class: AWSCDK::APIGatewayv2::WebSocketRouteProps
- Inherits:
-
WebSocketRouteOptions
- Object
- WebSocketRouteOptions
- AWSCDK::APIGatewayv2::WebSocketRouteProps
- Defined in:
- api_gatewayv2/web_socket_route_props.rb
Overview
Properties to initialize a new Route.
Instance Attribute Summary collapse
-
#api_key_required ⇒ Boolean?
readonly
Whether the route requires an API Key to be provided.
-
#authorizer ⇒ AWSCDK::APIGatewayv2::IWebSocketRouteAuthorizer?
readonly
The authorize to this route.
-
#integration ⇒ AWSCDK::APIGatewayv2::WebSocketRouteIntegration
readonly
The integration to be configured on this route.
-
#return_response ⇒ Boolean?
readonly
Should the route send a response to the client.
-
#route_key ⇒ String
readonly
The key to this route.
-
#web_socket_api ⇒ AWSCDK::APIGatewayv2::IWebSocketAPI
readonly
The API the route is associated with.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(integration:, authorizer: nil, return_response: nil, route_key:, web_socket_api:, api_key_required: nil) ⇒ WebSocketRouteProps
constructor
A new instance of WebSocketRouteProps.
- #to_jsii ⇒ Object
Constructor Details
#initialize(integration:, authorizer: nil, return_response: nil, route_key:, web_socket_api:, api_key_required: nil) ⇒ WebSocketRouteProps
Returns a new instance of WebSocketRouteProps.
13 14 15 16 17 18 19 20 21 22 23 24 25 26 |
# File 'api_gatewayv2/web_socket_route_props.rb', line 13 def initialize(integration:, authorizer: nil, return_response: nil, route_key:, web_socket_api:, api_key_required: nil) @integration = integration Jsii::Type.check_type(@integration, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfYXBpZ2F0ZXdheXYyLldlYlNvY2tldFJvdXRlSW50ZWdyYXRpb24ifQ==")), "integration") @authorizer = Jsii::Type.check_type(@authorizer, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfYXBpZ2F0ZXdheXYyLklXZWJTb2NrZXRSb3V0ZUF1dGhvcml6ZXIifQ==")), "authorizer") unless @authorizer.nil? @return_response = return_response Jsii::Type.check_type(@return_response, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJib29sZWFuIn0=")), "returnResponse") unless @return_response.nil? @route_key = route_key Jsii::Type.check_type(@route_key, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "routeKey") @web_socket_api = web_socket_api Jsii::Type.check_type(@web_socket_api, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfYXBpZ2F0ZXdheXYyLklXZWJTb2NrZXRBcGkifQ==")), "webSocketApi") @api_key_required = api_key_required Jsii::Type.check_type(@api_key_required, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJib29sZWFuIn0=")), "apiKeyRequired") unless @api_key_required.nil? end |
Instance Attribute Details
#api_key_required ⇒ Boolean? (readonly)
Note:
Default: false
Whether the route requires an API Key to be provided.
56 57 58 |
# File 'api_gatewayv2/web_socket_route_props.rb', line 56 def api_key_required @api_key_required end |
#authorizer ⇒ AWSCDK::APIGatewayv2::IWebSocketRouteAuthorizer? (readonly)
Note:
Default: - No Authorizer
The authorize to this route.
You can only set authorizer to a $connect route.
38 39 40 |
# File 'api_gatewayv2/web_socket_route_props.rb', line 38 def @authorizer end |
#integration ⇒ AWSCDK::APIGatewayv2::WebSocketRouteIntegration (readonly)
The integration to be configured on this route.
31 32 33 |
# File 'api_gatewayv2/web_socket_route_props.rb', line 31 def integration @integration end |
#return_response ⇒ Boolean? (readonly)
Note:
Default: false
Should the route send a response to the client.
43 44 45 |
# File 'api_gatewayv2/web_socket_route_props.rb', line 43 def return_response @return_response end |
#route_key ⇒ String (readonly)
The key to this route.
47 48 49 |
# File 'api_gatewayv2/web_socket_route_props.rb', line 47 def route_key @route_key end |
#web_socket_api ⇒ AWSCDK::APIGatewayv2::IWebSocketAPI (readonly)
The API the route is associated with.
51 52 53 |
# File 'api_gatewayv2/web_socket_route_props.rb', line 51 def web_socket_api @web_socket_api end |
Class Method Details
.jsii_properties ⇒ Object
58 59 60 61 62 63 64 65 66 67 |
# File 'api_gatewayv2/web_socket_route_props.rb', line 58 def self.jsii_properties { :integration => "integration", :authorizer => "authorizer", :return_response => "returnResponse", :route_key => "routeKey", :web_socket_api => "webSocketApi", :api_key_required => "apiKeyRequired", } end |
Instance Method Details
#to_jsii ⇒ Object
69 70 71 72 73 74 75 76 77 78 79 80 81 |
# File 'api_gatewayv2/web_socket_route_props.rb', line 69 def to_jsii result = {} result.merge!(super) result.merge!({ "integration" => @integration, "authorizer" => @authorizer, "returnResponse" => @return_response, "routeKey" => @route_key, "webSocketApi" => @web_socket_api, "apiKeyRequired" => @api_key_required, }) result.compact end |