Class: BodyEventMiddleware
Class: BodyEventMiddleware
Class representing a BodyEventMiddleware.
This middleware handles platform-specific messages and transforms them into Stone.js IncomingEvent objects.
Author
Mr. Stone
Constructors
Constructor
new BodyEventMiddleware(options): BodyEventMiddleware;
Create a BodyEventMiddleware.
Parameters
options
Options for creating the BodyEventMiddleware.
blueprint
IBlueprint
Returns
BodyEventMiddleware
Methods
handle()
handle(context, next): Promise<NodeHttpAdapterResponseBuilder>;
Handles the incoming event, processes it, and invokes the next middleware in the pipeline.
Parameters
context
The adapter context containing the raw event, execution context, and other data.
next
NextMiddleware
<NodeHttpAdapterContext
, NodeHttpAdapterResponseBuilder
>
The next middleware to be invoked in the pipeline.
Returns
Promise
<NodeHttpAdapterResponseBuilder
>
A promise that resolves to the destination type after processing.
Throws
If required components such as the rawEvent or IncomingEventBuilder are not provided.