diff options
author | Laurent Richard <[email protected]> | 2004-10-06 11:04:00 +0000 |
---|---|---|
committer | Laurent Richard <[email protected]> | 2004-10-06 11:04:00 +0000 |
commit | f3d249c81b6395550fe81c31da9a63b9146810cf (patch) | |
tree | c4c0bc7734bd1e73de314a7f2f2a1953f889a6a9 /src/header.hpp | |
parent | Fixed possible bug in destructor, when parent folder is closed before destroy... (diff) | |
download | vmime-f3d249c81b6395550fe81c31da9a63b9146810cf.tar.gz vmime-f3d249c81b6395550fe81c31da9a63b9146810cf.zip |
Adding functions in 'header' object to retrieve a list of fields by name/type
Diffstat (limited to 'src/header.hpp')
-rw-r--r-- | src/header.hpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/header.hpp b/src/header.hpp index 8ce070b9..b675e6fc 100644 --- a/src/header.hpp +++ b/src/header.hpp @@ -56,13 +56,11 @@ class header : public component friend class body; friend class message; -protected: +public: header(); ~header(); -public: - // A sub-class for field manipulation class fieldsContainer { @@ -125,6 +123,11 @@ public: headerField& find(const headerField::Types fieldType) const; headerField& find(const string& fieldName) const; + // Find all fields that matche the specified type/name. + // If no field is found, an empty vector is returned. + std::vector <headerField*> findAllByType(const headerField::Types fieldType); + std::vector <headerField*> findAllByName(const string& fieldName); + // Find the first field that matches the specified type/name. // If no field is found, one will be created. headerField& get(const headerField::Types fieldType); |