00001 
00002 
00003 
00004 
00005 
00006 
00007 
00008 
00009 
00010 
00011 
00012 
00013 
00014 
00015 
00016 
00017 
00018 
00019 
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