Struct httpbis::solicit::frame::headers::HeadersFrame [] [src]

pub struct HeadersFrame {
    pub stream_id: StreamId,
    pub stream_dep: Option<StreamDependency>,
    pub padding_len: Option<u8>,
    // some fields omitted
}

A struct representing the HEADERS frames of HTTP/2, as defined in the HTTP/2 spec, section 6.2.

Fields

The ID of the stream with which this frame is associated

The stream dependency information, if any.

The length of the padding, if any.

Methods

impl HeadersFrame
[src]

Creates a new HeadersFrame with the given header fragment and stream ID. No padding, no stream dependency, and no flags are set.

Creates a new HeadersFrame with the given header fragment, stream ID and stream dependency information. No padding and no flags are set.

Returns whether this frame ends the headers. If not, there MUST be a number of follow up CONTINUATION frames that send the rest of the header data.

Returns whther this frame ends the stream it is associated with.

Sets the padding length for the frame, as well as the corresponding Padded flag.

Sets the given flag for the frame.

Trait Implementations

impl PartialEq for HeadersFrame
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

impl Clone for HeadersFrame
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl Debug for HeadersFrame
[src]

Formats the value using the given formatter.

impl Frame for HeadersFrame
[src]

The type that represents the flags that the particular Frame can take. This makes sure that only valid Flags are used with each Frame.

Creates a new HeadersFrame with the given RawFrame (i.e. header and payload), if possible.

Returns

None if a valid HeadersFrame cannot be constructed from the given RawFrame. The stream ID must not be 0.

Otherwise, returns a newly constructed HeadersFrame.

Tests if the given flag is set for the frame.

Returns the StreamId of the stream to which the frame is associated.

A SettingsFrame always has to be associated to stream 0.

Returns a FrameHeader based on the current state of the Frame.

impl FrameIR for HeadersFrame
[src]

Write out the on-the-wire representation of the frame into the given FrameBuilder.