Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members  

skAttribute.h

00001 /*
00002   Copyright 1996-2003
00003   Simon Whiteside
00004 
00005     This library is free software; you can redistribute it and/or
00006     modify it under the terms of the GNU Lesser General Public
00007     License as published by the Free Software Foundation; either
00008     version 2 of the License, or (at your option) any later version.
00009 
00010     This library is distributed in the hope that it will be useful,
00011     but WITHOUT ANY WARRANTY; without even the implied warranty of
00012     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00013     Lesser General Public License for more details.
00014 
00015     You should have received a copy of the GNU Lesser General Public
00016     License along with this library; if not, write to the Free Software
00017     Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00018 
00019 * $Id: skAttribute_8h-source.html,v 1.5 2004/12/17 21:31:15 sdw Exp $
00020 */
00021 #ifndef skATTRIBUTE_H
00022 #define skATTRIBUTE_H
00023 
00024 #include "skAlist.h"
00025 #include "skString.h"
00026 class CLASSEXPORT skOutputDestination;
00030 class CLASSEXPORT skAttribute 
00031 #ifdef __SYMBIAN32__
00032 : public CBase
00033 #endif
00034 {
00035  public:
00040   inline skAttribute(const skString& name,const skString& value)
00041     : m_Name(name),m_Value(value){
00042   }
00046   inline skString getName() const {
00047     return m_Name;
00048   }
00052   inline skString getValue() const {
00053     return m_Value;
00054   }
00056   inline void setValue(const skString& name){
00057     m_Value=name;
00058   }
00063   IMPORT_C skString toString() const;
00068   IMPORT_C void write(skOutputDestination& out);
00069  private:
00070   skString m_Name;
00071   skString m_Value;
00072 };
00073 
00074 #ifdef INSTANTIATE_TEMPLATES
00075 EXTERN_TEMPLATE template class CLASSEXPORT skTAList<skAttribute>;
00076 #endif
00077 
00081 class CLASSEXPORT skAttributeList : public skTAList<skAttribute>
00082 {
00083  public:
00090   IMPORT_C void setAttribute(const skString& name,const skString& value);
00096   IMPORT_C skString getAttribute(const skString& name) const;
00103   IMPORT_C skString getAttribute(const skString& name,const skString& default_value) const;
00109   IMPORT_C bool removeAttribute(const skString& name);
00113   IMPORT_C skAttribute * findAttribute(const skString& name) const;
00114 };
00115 #endif

Generated on Fri Dec 17 20:28:26 2004 for Simkin C++ for Symbian by doxygen1.3