Crow  1.1
A C++ microframework for the web
crow::multipart Namespace Reference

Encapsulates anything related to processing and organizing multipart/xyz messages. More...

Classes

struct  header
 The first part in a section, contains metadata about the part. More...
 
struct  part
 One part of the multipart message. More...
 
struct  message
 The parsed multipart request/response. More...
 
struct  header_view
 The first part in a section, contains metadata about the part. More...
 
struct  padded
 String padded with the specified padding (double quotes by default) More...
 
struct  part_view
 One part of the multipart message. More...
 
struct  message_view
 The parsed multipart request/response. More...
 

Typedefs

using mph_map = std::unordered_multimap< std::string, header, ci_hash, ci_key_eq >
 Multipart header map (key is header key).
 
using mp_map = std::unordered_multimap< std::string, part, ci_hash, ci_key_eq >
 Multipart map (key is the name parameter).
 
using mph_view_map = std::unordered_multimap< std::string_view, header_view, ci_hash, ci_key_eq >
 Multipart header map (key is header key).
 
using mp_view_map = std::unordered_multimap< std::string_view, part_view, ci_hash, ci_key_eq >
 Multipart map (key is the name parameter).
 

Functions

template<typename O , typename T >
const O & get_header_value_object (const T &headers, const std::string &key)
 Find and return the value object associated with the key. (returns an empty class if nothing is found)
 
template<typename T >
const headerget_header_object (const T &headers, const std::string &key)
 Same as get_header_value_object() but for multipart::header.
 
const header_viewget_header_object (const mph_view_map &headers, const std::string_view key)
 Finds and returns the header with the specified key. (returns an empty header if nothing is found)
 

Variables

const std::string dd = "--"
 

Detailed Description

Encapsulates anything related to processing and organizing multipart/xyz messages.