@pumpkin-plugins/bedrock-addon-manager API / web/session / HttpSession
Class: HttpSession ​
Defined in: packages/bedrock-addon-manager/src/web/session.ts:35
One HTTP/1.1 exchange: read a request, send one response, close. Driven by tick().
Constructors ​
Constructor ​
new HttpSession(
transport,lookup,options):HttpSession
Defined in: packages/bedrock-addon-manager/src/web/session.ts:44
Starts waiting for a request on the transport.
Parameters ​
transport ​
lookup ​
options ​
Returns ​
HttpSession
Methods ​
abort() ​
abort():
false
Defined in: packages/bedrock-addon-manager/src/web/session.ts:73
Closes the connection and the pack file without finishing the response.
Returns ​
false
False, so callers can return session.abort() from a tick.
tick() ​
tick():
boolean
Defined in: packages/bedrock-addon-manager/src/web/session.ts:56
Moves the exchange forward: reads what has arrived, sends what fits, closes when done.
Returns ​
boolean
True while the session needs more ticks.