reSIProcate/stack  9694
PrivacyCategory.hxx
Go to the documentation of this file.
00001 #if !defined(RESIP_PRIVACY_CATEGORY_HXX)
00002 #define RESIP_PRIVACY_CATEGORY_HXX 
00003 
00004 #include <iosfwd>
00005 #include "rutil/Data.hxx"
00006 #include "resip/stack/ParserCategory.hxx"
00007 #include "resip/stack/ParserContainer.hxx"
00008 
00009 namespace resip
00010 {
00011 
00012 
00017 class PrivacyCategory : public ParserCategory
00018 {
00019    public:
00020       enum {commaHandling = CommasAllowedOutputCommas};
00021 
00022       PrivacyCategory();
00023       explicit PrivacyCategory(const Data& d);
00024       PrivacyCategory(const HeaderFieldValue& hfv, 
00025                         Headers::Type type,
00026                         PoolBase* pool=0);
00027       PrivacyCategory(const PrivacyCategory& orig,
00028                         PoolBase* pool=0);
00029       PrivacyCategory& operator=(const PrivacyCategory&);
00030 
00031       const std::vector<Data>& value() const;
00032       std::vector<Data>& value();
00033 
00034       virtual void parse(ParseBuffer& pb); // remember to call parseParameters()
00035       virtual ParserCategory* clone() const;
00036       virtual ParserCategory* clone(void* location) const;
00037       virtual ParserCategory* clone(PoolBase* pool) const;
00038       virtual EncodeStream& encodeParsed(EncodeStream& str) const;
00039    private:
00040       std::vector<Data> mValue;
00041 };
00042 typedef ParserContainer<PrivacyCategory> PrivacyCategories;
00043  
00044 }
00045 
00046 #endif
00047 
00048 /* ====================================================================
00049  * The Vovida Software License, Version 1.0 
00050  * 
00051  * Copyright (c) 2000-2005 Vovida Networks, Inc.  All rights reserved.
00052  * 
00053  * Redistribution and use in source and binary forms, with or without
00054  * modification, are permitted provided that the following conditions
00055  * are met:
00056  * 
00057  * 1. Redistributions of source code must retain the above copyright
00058  *    notice, this list of conditions and the following disclaimer.
00059  * 
00060  * 2. Redistributions in binary form must reproduce the above copyright
00061  *    notice, this list of conditions and the following disclaimer in
00062  *    the documentation and/or other materials provided with the
00063  *    distribution.
00064  * 
00065  * 3. The names "VOCAL", "Vovida Open Communication Application Library",
00066  *    and "Vovida Open Communication Application Library (VOCAL)" must
00067  *    not be used to endorse or promote products derived from this
00068  *    software without prior written permission. For written
00069  *    permission, please contact vocal@vovida.org.
00070  *
00071  * 4. Products derived from this software may not be called "VOCAL", nor
00072  *    may "VOCAL" appear in their name, without prior written
00073  *    permission of Vovida Networks, Inc.
00074  * 
00075  * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESSED OR IMPLIED
00076  * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
00077  * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, TITLE AND
00078  * NON-INFRINGEMENT ARE DISCLAIMED.  IN NO EVENT SHALL VOVIDA
00079  * NETWORKS, INC. OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT DAMAGES
00080  * IN EXCESS OF $1,000, NOR FOR ANY INDIRECT, INCIDENTAL, SPECIAL,
00081  * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
00082  * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
00083  * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
00084  * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
00085  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE
00086  * USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
00087  * DAMAGE.
00088  * 
00089  * ====================================================================
00090  * 
00091  * This software consists of voluntary contributions made by Vovida
00092  * Networks, Inc. and many individuals on behalf of Vovida Networks,
00093  * Inc.  For more information on Vovida Networks, Inc., please see
00094  * <http://www.vovida.org/>.
00095  *
00096  */