Node.Http2.Stream
- Package
- purescript-node-http2
- Repository
- purescript-node/purescript-node-http2
#toDuplex Source
toDuplex :: forall endpoint. Http2Stream endpoint -> Duplex#abortedH Source
abortedH :: forall endpoint. EventHandle0 (Http2Stream endpoint)#closeH Source
closeH :: forall endpoint. EventHandle0 (Http2Stream endpoint)#errorH Source
errorH :: forall endpoint. EventHandle1 (Http2Stream endpoint) Error#frameErrorH Source
frameErrorH :: forall endpoint. EventHandle3 (Http2Stream endpoint) FrameType ErrorCode StreamId#readyH Source
readyH :: forall endpoint. EventHandle0 (Http2Stream endpoint)#timeoutH Source
timeoutH :: forall endpoint. EventHandle0 (Http2Stream endpoint)#trailersH Source
trailersH :: forall endpoint. EventHandle2 (Http2Stream endpoint) Settings BitwiseFlag#wantTrailersH Source
wantTrailersH :: forall endpoint. EventHandle0 (Http2Stream endpoint)#bufferSize Source
bufferSize :: forall endpoint. Http2Stream endpoint -> Effect Int#endAfterHeaders Source
endAfterHeaders :: forall endpoint. Http2Stream endpoint -> Effect Boolean#PriorityOptions Source
type PriorityOptions = { exclusive :: Boolean, parent :: Int, silent :: Boolean, weight :: Int }exclusive <boolean> When true and parent identifies a parent Stream, this stream is made the sole direct dependency of the parent, with all other existing dependents made a dependent of this stream. Default: false.
parent <number> Specifies the numeric identifier of a stream this stream is dependent on.
weight <number> Specifies the relative dependency of a stream in relation to other streams with the same parent. The value is a number between 1 and 256 (inclusive).
silent <boolean> When true, changes the priority locally without sending a PRIORITY frame to the connected peer.
#priority Source
priority :: forall endpoint. Http2Stream endpoint -> PriorityOptions -> Effect UnitNote: clamping the weight value is done automatically.
#sentHeaders Source
sentHeaders :: forall endpoint. Http2Stream endpoint -> Effect Headers#sentInfoHeaders Source
sentInfoHeaders :: forall endpoint. Http2Stream endpoint -> Effect (Array Headers)#sentTrailers Source
sentTrailers :: forall endpoint. Http2Stream endpoint -> Effect Headers#session Source
session :: forall endpoint. Http2Stream endpoint -> Effect (Maybe (Http2Session endpoint))#setTimeout Source
setTimeout :: forall endpoint. Http2Stream endpoint -> Milliseconds -> Effect Unit -> Effect Unit#Http2StreamState Source
type Http2StreamState = { localClose :: Int, localWindowSize :: Int, remoteClose :: Int, state :: BitwiseFlag, sumDependencyWeight :: Int, weight :: Int }localWindowSize <number> The number of bytes the connected peer may send for this Http2Stream peer without receiving a WINDOW_UPDATE.
state <number> A flag indicating the low-level current state of the Http2Stream peer as determined by nghttp2.
localClose <number> 1 if this Http2Stream peer has been closed locally.
remoteClose <number> 1 if this Http2Stream peer has been closed remotely.
sumDependencyWeight <number> The sum weight of all Http2Stream peer instances that depend on this Http2Stream peer as specified using PRIORITY frames.
weight <number> The priority weight of this Http2Stream peer.
#state Source
state :: forall endpoint. Http2Stream endpoint -> Effect Http2StreamState#sendTrailers Source
sendTrailers :: forall endpoint. Http2Stream endpoint -> Headers -> Effect Unit#additionalHeaders Source
additionalHeaders :: Http2Stream Server -> Headers -> Effect Unit#PushStreamOptions Source
type PushStreamOptions = { exclusive :: Boolean, parent :: Int }exclusive <boolean> When true and parent identifies a parent Stream, the created stream is made the sole direct dependency of the parent, with all other existing dependents made a dependent of the newly created stream. Default: false.
parent <number> Specifies the numeric identifier of a stream the newly created stream is dependent on.
#pushStream Source
pushStream :: Http2Stream Server -> Headers -> (Either Error (Http2Stream Server) -> Headers -> Effect Unit) -> Effect Unit#pushStream' Source
pushStream' :: Http2Stream Server -> Headers -> PushStreamOptions -> (Either Error (Http2Stream Server) -> Headers -> Effect Unit) -> Effect Unit#RespondOptions Source
type RespondOptions = { endStream :: Boolean, waitForTrailers :: Boolean }endStream <boolean> Set to true to indicate that the response will not include payload data.
waitForTailers <boolean> When true, the Http2Stream will emit the 'wantTrailers' event after the final DATA frame has been sent.
#respond Source
respond :: Http2Stream Server -> Headers -> RespondOptions -> Effect Unit#RespondWithFdOptions Source
type RespondWithFdOptions = { length :: Int, offset :: Int, waitForTrailers :: Boolean }waitForTrailers <boolean> When true, the Http2Stream will emit the 'wantTrailers' event after the final DATA frame has been sent.
offset <number> The offset position at which to begin reading.
length <number> The amount of data from the fd to send.
Note: statCheck function intentionally not supported.
#respondWithFd Source
respondWithFd :: Http2Stream Server -> FileDescriptor -> Headers -> RespondWithFdOptions -> Effect Unit#RespondWithFileOptions Source
type RespondWithFileOptions = { length :: Int, offset :: Int, waitForTrailers :: Boolean }waitForTrailers <boolean> When true, the Http2Stream will emit the 'wantTrailers' event after the final DATA frame has been sent.
offset <number> The offset position at which to begin reading.
length <number> The amount of data from the fd to send.
Note: statCheck and onError intentionally not supported.
#respondWithFile Source
respondWithFile :: Http2Stream Server -> FilePath -> Headers -> RespondWithFileOptions -> Effect Unit