]> git.tdb.fi Git - libs/net.git/blobdiff - source/message.h
Use maputils.h
[libs/net.git] / source / message.h
index 1ccc976ac71c76c3a8517e181a79ac2ab54f27c6..4d2310273f8b3fd0e4b0014aede99623028cd023 100644 (file)
@@ -1,10 +1,3 @@
-/* $Id$
-
-This file is part of libmsphttp
-Copyright © 2008  Mikkosoft Productions, Mikko Rasa
-Distributed under the LGPL
-*/
-
 #ifndef MSP_HTTP_MESSAGE_H_
 #define MSP_HTTP_MESSAGE_H_
 
@@ -33,16 +26,19 @@ public:
        virtual ~Message() { }
 
        void set_header(const std::string &, const std::string &);
+       bool has_header(const std::string &) const;
        const std::string &get_header(const std::string &) const;
        void add_content(const std::string &);
        const std::string &get_content() const { return content; }
        void set_user_data(const Variant &);
        const Variant &get_user_data() const { return user_data; }
-       bool get_complete() const { return complete; }
+       bool is_complete() const { return complete; }
        unsigned parse_content(const std::string &);
-       virtual std::string str() const =0;
+       virtual std::string str() const = 0;
 protected:
+       unsigned parse_headers(const std::string &);
        std::string str_common() const;
+       std::string normalize_header_name(const std::string &) const;
 };
 
 } // namespace Http