2 * Copyright (C) 2005-2018 Team Kodi
3 * This file is part of Kodi - https://kodi.tv
5 * SPDX-License-Identifier: GPL-2.0-or-later
6 * See LICENSES/README.md for more information.
18 typedef std::pair
<std::string
, std::string
> HeaderParamValue
;
19 typedef std::vector
<HeaderParamValue
> HeaderParams
;
20 typedef HeaderParams::iterator HeaderParamsIter
;
25 void Parse(const std::string
& strData
);
26 void AddParam(const std::string
& param
, const std::string
& value
, const bool overwrite
= false);
28 std::string
GetValue(const std::string
& strParam
) const;
29 std::vector
<std::string
> GetValues(std::string strParam
) const;
31 std::string
GetHeader(void) const;
33 std::string
GetMimeType(void) const;
34 std::string
GetCharset(void) const;
35 inline const std::string
& GetProtoLine() const { return m_protoLine
; }
37 inline bool IsHeaderDone(void) const
38 { return m_headerdone
; }
43 std::string
GetValueRaw(const std::string
& strParam
) const;
44 bool ParseLine(const std::string
& headerLine
);
46 HeaderParams m_params
;
47 std::string m_protoLine
;
49 std::string m_lastHeaderLine
;
50 static const char* const m_whitespaceChars
;