Module

Node.Http2.Flags

Package
purescript-node-http2
Repository
purescript-node/purescript-node-http2

Defines a Bitwise flag and the two operations used in this context. Also groups all flags that can be used in a given frame type into a record with a corresponding name. For example, the DATA frame can use flags found in the dataFlags record.

#BitwiseFlag Source

newtype BitwiseFlag

An integer whose bits store bitwise flags

Instances

#enable Source

enable :: BitwiseFlag -> BitwiseFlag -> BitwiseFlag

Enable two flags.

enable endStream padded

#isDisabled Source

isDisabled :: BitwiseFlag -> BitwiseFlag -> Boolean

Checks whether the first arg, the input, has disabled the flag represented by the second arg, endStream.

isDisabled input endStream

#isEnabled Source

isEnabled :: BitwiseFlag -> BitwiseFlag -> Boolean

Checks whether the first arg, the input, has enabled the flag represented by the second arg, endStream.

isEnabled input endStream

#endStream Source

endStream :: BitwiseFlag
  • on DATA frames, indicates that this frame is the last that the endpoint will send for the identified stream. Setting this flag causes the stream to enter one of the "half-closed" states or the "closed" state
  • on HEADERS frames, indicates that the header block (Section 4.3) is the last that the endpoint will send for the identified stream.

#ack Source

ack :: BitwiseFlag
  • on SETTINGS frames, indicates that this frame acknowledges receipt and application of the peer's SETTINGS frame. When this bit is set, the payload of the SETTINGS frame MUST be empty. Receipt of a SETTINGS frame with the ACK flag set and a length field value other than 0 MUST be treated as a connection error (Section 5.4.1) of type FRAME_SIZE_ERROR. For more information, see Section 6.5.3 ("Settings Synchronization")
  • on PING frames, indicates that this PING frame is a PING response. An endpoint MUST set this flag in PING responses. An endpoint MUST NOT respond to PING frames containing this flag.

#endHeaders Source

endHeaders :: BitwiseFlag
  • on HEADERS frames, indicates that this frame contains an entire header block (Section 4.3) and is not followed by any CONTINUATION frames.
  • on PUSH_PROMISE frames, indicates that this frame contains an entire header block (Section 4.3) and is not followed by any CONTINUATION frames.
  • on CONTINUATION frames, indicates that this frame ends a header block (Section 4.3).

#padded Source

padded :: BitwiseFlag
  • on DATA frames, indicates that the Pad Length field and any padding that it describes are present.
  • on HEADERS frames, indicates that the Pad Length field and any padding that it describes are present.
  • on PUSH_PROMISE frames, indicates that the Pad Length field and any padding that it describes are present.

#priority Source

priority :: BitwiseFlag
  • on HEADERS frames, indicates that the Exclusive Flag (E), Stream Dependency, and Weight fields are present; see Section 5.3.

#dataFlags Source

dataFlags :: { endStream :: BitwiseFlag, padded :: BitwiseFlag }

#headersFlags Source

headersFlags :: { endHeaders :: BitwiseFlag, endStream :: BitwiseFlag, padded :: BitwiseFlag, priority :: BitwiseFlag }

#settingsFlags Source

#pushPromiseFlags Source

pushPromiseFlags :: { endHeaders :: BitwiseFlag, padded :: BitwiseFlag }

#pingFlags Source

pingFlags :: { ack :: BitwiseFlag }

#continuationFlags Source

continuationFlags :: { endHeaders :: BitwiseFlag }