00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035 #ifndef INCL_DEVICE_CONFIG
00036 #define INCL_DEVICE_CONFIG
00037
00039 #include "base/fscapi.h"
00040 #include "spds/constants.h"
00041 #include "syncml/core/VerDTD.h"
00042 #include "base/Log.h"
00043 #include "base/globalsdef.h"
00044
00045 BEGIN_NAMESPACE
00046
00047
00048
00049
00050
00051
00052
00053
00054
00055 class DeviceConfig {
00056
00057 private:
00058
00059 char* man ;
00060 char* mod ;
00061 char* oem ;
00062 char* fwv ;
00063 char* swv ;
00064 char* hwv ;
00065 char* devID ;
00066 char* devType ;
00067 char* dsV ;
00068 bool utc ;
00069 bool loSupport ;
00070 bool nocSupport ;
00071 LogLevel logLevel ;
00072 unsigned int maxObjSize ;
00073 char* devInfHash ;
00074
00075
00076
00077 int smartSlowSync;
00078 char* verDTD;
00079
00080
00088 void set(char* * buf, const char* v);
00089
00090
00091 public:
00092
00093 DeviceConfig();
00094 DeviceConfig(DeviceConfig& s);
00095 ~DeviceConfig();
00096
00097
00109 const char* getMan() const ;
00110 void setMan(const char* v) ;
00111
00112 const char* getMod() const ;
00113 void setMod(const char* v) ;
00114
00115 const char* getOem() const ;
00116 void setOem(const char* v) ;
00117
00118 const char* getFwv() const ;
00119 void setFwv(const char* v) ;
00120
00121 const char* getSwv() const ;
00122 void setSwv(const char* v) ;
00123
00124 const char* getHwv() const ;
00125 void setHwv(const char* v) ;
00126
00127 const char* getDevID() const ;
00128 void setDevID(const char* v) ;
00129
00130 const char* getDevType() const ;
00131 void setDevType(const char* v) ;
00132
00133 const char* getDsV() const ;
00134 void setDsV(const char* v) ;
00135
00136 bool getUtc() const ;
00137 void setUtc(bool v) ;
00138
00139 bool getLoSupport() const ;
00140 void setLoSupport(bool v) ;
00141
00142 bool getNocSupport() const ;
00143 void setNocSupport(bool v) ;
00144
00145 LogLevel getLogLevel() const ;
00146 void setLogLevel(LogLevel v) ;
00147
00148 unsigned int getMaxObjSize() const ;
00149 void setMaxObjSize(unsigned int v) ;
00150
00151 const char* getDevInfHash() const ;
00152 void setDevInfHash(const char *v) ;
00153
00154 int getSmartSlowSync() const;
00155 void setSmartSlowSync(int v);
00156
00157 const char* getVerDTD() const ;
00158 void setVerDTD(const char* v) ;
00159
00166 void assign(const DeviceConfig& s);
00167
00168
00169
00170
00171 DeviceConfig& operator = (const DeviceConfig& dc) {
00172 assign(dc);
00173 return *this;
00174 }
00175 };
00176
00177
00178 END_NAMESPACE
00179
00181 #endif