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
00036
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048
00049
00050
00051
00052
00053
00054
00055
00056
00057
00058
00059
00060
00061
00062
00063
00064
00065
00066
00067
00068
00069
00070
00071
00072
00073
00074
00075
00076
00077
00078
00079
00080
00081
00082
00083
00084
00085
00086
00087
00088
00089
00090
00091
00092
00093
00094
00095
00096
00097
00098
00099
00100
00101
00102
00103
00104 #ifndef INPUTSOURCE_HPP
00105 #define INPUTSOURCE_HPP
00106
00107 #include <xercesc/util/XercesDefs.hpp>
00108
00109 class BinInputStream;
00110
00111
00142 class InputSource
00143 {
00144 public:
00145
00146
00147
00150
00154 virtual ~InputSource();
00156
00157
00158
00161
00171 virtual BinInputStream* makeStream() const = 0;
00172
00174
00175
00176
00179
00188 const XMLCh* getEncoding() const;
00189
00190
00197 const XMLCh* getPublicId() const;
00198
00199
00208 const XMLCh* getSystemId() const;
00209
00218 const bool getIssueFatalErrorIfNotFound() const;
00219
00221
00222
00223
00226
00238 void setEncoding(const XMLCh* const encodingStr);
00239
00240
00252 void setPublicId(const XMLCh* const publicId);
00253
00270 void setSystemId(const XMLCh* const systemId);
00271
00281 void setIssueFatalErrorIfNotFound(const bool flag);
00282
00284
00285
00286 protected :
00287
00288
00289
00292
00293 InputSource();
00294
00298 InputSource(const XMLCh* const systemId);
00299
00304 InputSource
00305 (
00306 const XMLCh* const systemId
00307 , const XMLCh* const publicId
00308 );
00309
00313 InputSource(const char* const systemId);
00314
00319 InputSource
00320 (
00321 const char* const systemId
00322 , const char* const publicId
00323 );
00324
00326
00327
00328
00329
00330
00331 private:
00332
00333
00334
00335 InputSource(const InputSource&);
00336 void operator=(const InputSource&);
00337
00338
00339
00340
00341
00342
00343
00344
00345
00346
00347
00348
00349
00350
00351
00352
00353
00354
00355
00356
00357 XMLCh* fEncoding;
00358 XMLCh* fPublicId;
00359 XMLCh* fSystemId;
00360 bool fFatalErrorIfNotFound;
00361 };
00362
00363
00364
00365
00366
00367 inline const XMLCh* InputSource::getEncoding() const
00368 {
00369 return fEncoding;
00370 }
00371
00372 inline const XMLCh* InputSource::getPublicId() const
00373 {
00374 return fPublicId;
00375 }
00376
00377 inline const XMLCh* InputSource::getSystemId() const
00378 {
00379 return fSystemId;
00380 }
00381
00382 inline const bool InputSource::getIssueFatalErrorIfNotFound() const
00383 {
00384 return fFatalErrorIfNotFound;
00385 }
00386
00387
00388
00389
00390 inline void InputSource::setIssueFatalErrorIfNotFound(const bool flag)
00391 {
00392 fFatalErrorIfNotFound = flag;
00393 }
00394
00395 #endif