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
00083 void set(char* * buf, const char* v);
00084
00085
00086 public:
00087
00088 DeviceConfig();
00089 DeviceConfig(DeviceConfig& s);
00090 ~DeviceConfig();
00091
00092
00104 const char* getMan() const ;
00105 void setMan(const char* v) ;
00106
00107 const char* getMod() const ;
00108 void setMod(const char* v) ;
00109
00110 const char* getOem() const ;
00111 void setOem(const char* v) ;
00112
00113 const char* getFwv() const ;
00114 void setFwv(const char* v) ;
00115
00116 const char* getSwv() const ;
00117 void setSwv(const char* v) ;
00118
00119 const char* getHwv() const ;
00120 void setHwv(const char* v) ;
00121
00122 const char* getDevID() const ;
00123 void setDevID(const char* v) ;
00124
00125 const char* getDevType() const ;
00126 void setDevType(const char* v) ;
00127
00128 const char* getDsV() const ;
00129 void setDsV(const char* v) ;
00130
00131 bool getUtc() const ;
00132 void setUtc(bool v) ;
00133
00134 bool getLoSupport() const ;
00135 void setLoSupport(bool v) ;
00136
00137 bool getNocSupport() const ;
00138 void setNocSupport(bool v) ;
00139
00140 LogLevel getLogLevel() const ;
00141 void setLogLevel(LogLevel v) ;
00142
00143 unsigned int getMaxObjSize() const ;
00144 void setMaxObjSize(unsigned int v) ;
00145
00146 const char* getDevInfHash() const ;
00147 void setDevInfHash(const char *v) ;
00148
00155 void assign(const DeviceConfig& s);
00156
00157
00158
00159
00160 DeviceConfig& operator = (const DeviceConfig& dc) {
00161 assign(dc);
00162 return *this;
00163 }
00164 };
00165
00166
00167 END_NAMESPACE
00168
00170 #endif