proxygen
proxygen::compress::Header Struct Reference

#include <Header.h>

Public Member Functions

 Header (HTTPHeaderCode c, const std::string &v)
 
 Header (HTTPHeaderCode c, const std::string &n, const std::string &v)
 
bool operator< (const Header &h) const
 

Static Public Member Functions

static Header makeHeaderForTest (const std::string &n, const std::string &v)
 

Public Attributes

HTTPHeaderCode code
 
const std::stringname
 
const std::stringvalue
 

Private Member Functions

 Header (const std::string &n, const std::string &v)
 

Detailed Description

Helper structure used when serializing the uncompressed representation of a header name/value list.

Definition at line 21 of file Header.h.

Constructor & Destructor Documentation

proxygen::compress::Header::Header ( HTTPHeaderCode  c,
const std::string v 
)
inline

Definition at line 26 of file Header.h.

Referenced by makeHeaderForTest().

const std::string * value
Definition: Header.h:24
const std::string * name
Definition: Header.h:23
HTTPHeaderCode code
Definition: Header.h:22
static const std::string * getPointerToHeaderName(HTTPHeaderCode code, HTTPCommonHeaderTableType type=TABLE_CAMELCASE)
char c
proxygen::compress::Header::Header ( HTTPHeaderCode  c,
const std::string n,
const std::string v 
)
inline

Definition at line 30 of file Header.h.

33  : code(c), name(&n), value(&v) {}
const std::string * value
Definition: Header.h:24
const std::string * name
Definition: Header.h:23
HTTPHeaderCode code
Definition: Header.h:22
char c
proxygen::compress::Header::Header ( const std::string n,
const std::string v 
)
inlineprivate

Definition at line 49 of file Header.h.

50  : code(HTTPCommonHeaders::hash(n)), name(&n), value(&v) {}
const std::string * value
Definition: Header.h:24
const std::string * name
Definition: Header.h:23
HTTPHeaderCode code
Definition: Header.h:22
static FB_EXPORT HTTPHeaderCode hash(const char *name, size_t len)

Member Function Documentation

static Header proxygen::compress::Header::makeHeaderForTest ( const std::string n,
const std::string v 
)
inlinestatic

Definition at line 41 of file Header.h.

References Header().

Referenced by proxygen::hpack::headersFromArray(), and TEST_F().

41  {
42  return Header(n, v);
43  }
Header(HTTPHeaderCode c, const std::string &v)
Definition: Header.h:26
bool proxygen::compress::Header::operator< ( const Header h) const
inline

Definition at line 35 of file Header.h.

References code, and name.

35  {
36  return (code < h.code) ||
37  ((code == h.code) && (*name < *h.name));
38  }
*than *hazptr_holder h
Definition: Hazptr.h:116
const std::string * name
Definition: Header.h:23
HTTPHeaderCode code
Definition: Header.h:22

Member Data Documentation

HTTPHeaderCode proxygen::compress::Header::code

Definition at line 22 of file Header.h.

Referenced by operator<().

const std::string* proxygen::compress::Header::name

Definition at line 23 of file Header.h.

Referenced by operator<().

const std::string* proxygen::compress::Header::value

Definition at line 24 of file Header.h.


The documentation for this struct was generated from the following file: