31 #ifndef CPL_CONV_H_INCLUDED
32 #define CPL_CONV_H_INCLUDED
50 void CPL_DLL CPLVerifyConfiguration(
void);
52 const char CPL_DLL * CPL_STDCALL
56 const
char *pszValue );
57 void CPL_DLL CPL_STDCALL CPLFreeConfig(
void);
63 void CPL_DLL *
CPLMalloc(
size_t ) CPL_WARN_UNUSED_RESULT;
64 void CPL_DLL *
CPLCalloc(
size_t,
size_t ) CPL_WARN_UNUSED_RESULT;
65 void CPL_DLL *
CPLRealloc(
void *,
size_t ) CPL_WARN_UNUSED_RESULT;
66 char CPL_DLL *
CPLStrdup( const
char * ) CPL_WARN_UNUSED_RESULT;
69 #define CPLFree VSIFree
74 char CPL_DLL *
CPLFGets(
char *,
int, FILE *);
77 const char CPL_DLL *
CPLReadLine2L( VSILFILE * ,
int nMaxCols,
char** papszOptions);
83 double CPL_DLL
CPLAtof(
const char *);
85 double CPL_DLL
CPLStrtod(
const char *,
char **);
87 float CPL_DLL
CPLStrtof(
const char *,
char **);
94 double CPL_DLL
CPLAtofM(
const char *);
102 unsigned long CPL_DLL
CPLScanULong(
const char *,
int );
113 int CPL_DLL
CPLPrintDouble(
char *,
const char *,
double,
const char * );
114 int CPL_DLL
CPLPrintTime(
char *,
int ,
const char *,
const struct tm *,
122 void CPL_DLL *
CPLGetSymbol(
const char *,
const char * );
132 const char CPL_DLL *
CPLGetPath(
const char * );
139 const char *pszBasename,
140 const char *pszExtension );
142 const char *pszBasename,
143 const char *pszExtension );
146 const char *pszSecondaryFilename );
151 const char *pszNewFilename,
152 char **papszFileList );
153 int CPL_DLL
CPLCheckForFile(
char *pszFilename,
char **papszSiblingList );
160 typedef const char *(*CPLFileFinder)(
const char *,
const char *);
162 const char CPL_DLL *CPLFindFile(
const char *pszClass,
163 const char *pszBasename);
164 const char CPL_DLL *CPLDefaultFindFile(
const char *pszClass,
165 const char *pszBasename);
166 void CPL_DLL CPLPushFileFinder( CPLFileFinder pfnFinder );
167 CPLFileFinder CPL_DLL CPLPopFileFinder(
void);
168 void CPL_DLL CPLPushFinderLocation(
const char * );
169 void CPL_DLL CPLPopFinderLocation(
void);
170 void CPL_DLL CPLFinderClean(
void);
175 int CPL_DLL CPLStat(
const char *, VSIStatBuf * );
189 FILE CPL_DLL *
CPLOpenShared(
const char *,
const char *,
int );
193 void CPL_DLL CPLCleanupSharedFileMutex();
198 double CPL_DLL CPLDMSToDec(
const char *is );
199 const char CPL_DLL *CPLDecToDMS(
double dfAngle,
const char * pszAxis,
204 void CPL_DLL CPLStringToComplex(
const char *pszString,
205 double *pdfReal,
double *pdfImag );
211 int CPL_DLL CPLCopyFile(
const char *pszNewPath,
const char *pszOldPath );
212 int CPL_DLL CPLMoveFile(
const char *pszNewPath,
const char *pszOldPath );
217 #define CPL_ZIP_API_OFFERED
218 void CPL_DLL *CPLCreateZip(
const char *pszZipFilename,
char **papszOptions );
219 CPLErr CPL_DLL CPLCreateFileInZip(
void *hZip,
const char *pszFilename,
220 char **papszOptions );
221 CPLErr CPL_DLL CPLWriteFileInZip(
void *hZip,
const void *pBuffer,
int nBufferSize );
222 CPLErr CPL_DLL CPLCloseFileInZip(
void *hZip );
223 CPLErr CPL_DLL CPLCloseZip(
void *hZip );
229 void CPL_DLL *
CPLZLibDeflate(
const void* ptr,
size_t nBytes,
int nLevel,
230 void* outptr,
size_t nOutAvailableBytes,
231 size_t* pnOutBytes );
233 void* outptr,
size_t nOutAvailableBytes,
234 size_t* pnOutBytes );
239 int CPL_DLL CPLValidateXML(
const char* pszXMLFilename,
240 const char* pszXSDFilename,
241 char** papszOptions);
249 #if defined(__cplusplus) && !defined(CPL_SUPRESS_CPLUSPLUS)
251 class CPL_DLL CPLLocaleC
261 CPLLocaleC(CPLLocaleC&);
262 CPLLocaleC& operator=(CPLLocaleC&);
double CPL_DLL CPLAtofM(const char *)
Definition: cpl_strtod.cpp:161
double CPL_DLL CPLStrtod(const char *, char **)
Definition: cpl_strtod.cpp:318
int CPL_DLL CPLPrintString(char *, const char *, int)
Definition: cpl_conv.cpp:1061
GUIntBig CPL_DLL CPLScanUIntBig(const char *, int)
Definition: cpl_conv.cpp:900
const char CPL_DLL * CPLProjectRelativeFilename(const char *pszProjectDir, const char *pszSecondaryFilename)
Definition: cpl_path.cpp:626
int CPL_DLL CPLPrintInt32(char *, GInt32, int)
Definition: cpl_conv.cpp:1150
void CPL_DLL * CPLZLibDeflate(const void *ptr, size_t nBytes, int nLevel, void *outptr, size_t nOutAvailableBytes, size_t *pnOutBytes)
Compress a buffer with ZLib DEFLATE compression.
Definition: cpl_conv.cpp:2528
int CPL_DLL CPLPrintTime(char *, int, const char *, const struct tm *, const char *)
Definition: cpl_conv.cpp:1370
const char CPL_DLL * CPLGetPath(const char *)
Definition: cpl_path.cpp:128
const char CPL_DLL * CPLFormCIFilename(const char *pszPath, const char *pszBasename, const char *pszExtension)
Definition: cpl_path.cpp:531
unsigned long CPL_DLL CPLScanULong(const char *, int)
Definition: cpl_conv.cpp:860
const char CPL_DLL * CPLGetDirname(const char *)
Definition: cpl_path.cpp:181
CPLSharedFileInfo CPL_DLL * CPLGetSharedList(int *)
Definition: cpl_conv.cpp:2167
const char CPL_DLL * CPLGetBasename(const char *)
Definition: cpl_path.cpp:262
const char CPL_DLL * CPLReadLine(FILE *)
Definition: cpl_conv.cpp:514
double CPL_DLL CPLDecToPackedDMS(double dfDec)
Definition: cpl_conv.cpp:1934
int CPL_DLL CPLPrintDouble(char *, const char *, double, const char *)
Definition: cpl_conv.cpp:1280
double CPL_DLL CPLScanDouble(const char *, int)
Definition: cpl_conv.cpp:1014
void CPL_DLL CPL_STDCALL CPLSetThreadLocalConfigOption(const char *pszKey, const char *pszValue)
Definition: cpl_conv.cpp:1640
char CPL_DLL * CPLStrdup(const char *) CPL_WARN_UNUSED_RESULT
Definition: cpl_conv.cpp:243
double CPL_DLL CPLAtofDelim(const char *, char)
Definition: cpl_strtod.cpp:94
const char CPL_DLL * CPLReadLineL(VSILFILE *)
Definition: cpl_conv.cpp:579
char CPL_DLL * CPLStrlwr(char *)
Definition: cpl_conv.cpp:278
int CPL_DLL CPLGetExecPath(char *pszPathBuf, int nMaxLength)
Definition: cpl_getexecpath.cpp:138
const char CPL_DLL * CPLFormFilename(const char *pszPath, const char *pszBasename, const char *pszExtension)
Definition: cpl_path.cpp:459
void CPL_DLL CPL_STDCALL CPLSetConfigOption(const char *, const char *)
Definition: cpl_conv.cpp:1605
FILE CPL_DLL * CPLOpenShared(const char *, const char *, int)
Definition: cpl_conv.cpp:2012
const char CPL_DLL * CPLGenerateTempFilename(const char *pszStem)
Definition: cpl_path.cpp:976
char CPL_DLL * CPLScanString(const char *, int, int, int)
Definition: cpl_conv.cpp:765
const char CPL_DLL * CPLReadLine2L(VSILFILE *, int nMaxCols, char **papszOptions)
Definition: cpl_conv.cpp:604
Definition: cpl_conv.h:181
char CPL_DLL * CPLFGets(char *, int, FILE *)
Definition: cpl_conv.cpp:319
char CPL_DLL * CPLGetCurrentDir(void)
Definition: cpl_path.cpp:347
void CPL_DLL * CPLMalloc(size_t) CPL_WARN_UNUSED_RESULT
Definition: cpl_conv.cpp:114
int CPL_DLL CPLPrintUIntBig(char *, GUIntBig, int)
Definition: cpl_conv.cpp:1189
const char CPL_DLL * CPLGetExtension(const char *)
Definition: cpl_path.cpp:312
double CPL_DLL CPLAtof(const char *)
Definition: cpl_strtod.cpp:136
int CPL_DLL CPLPrintPointer(char *, void *, int)
Definition: cpl_conv.cpp:1231
int CPL_DLL CPLPrintStringFill(char *, const char *, int)
Definition: cpl_conv.cpp:1105
char CPL_DLL ** CPLCorrespondingPaths(const char *pszOldFilename, const char *pszNewFilename, char **papszFileList)
Definition: cpl_path.cpp:866
void CPL_DLL CPLDumpSharedList(FILE *)
Definition: cpl_conv.cpp:2189
const char CPL_DLL *CPL_STDCALL CPLGetConfigOption(const char *, const char *) CPL_WARN_UNUSED_RESULT
Definition: cpl_conv.cpp:1543
void CPL_DLL * CPLRealloc(void *, size_t) CPL_WARN_UNUSED_RESULT
Definition: cpl_conv.cpp:177
const char CPL_DLL * CPLExtractRelativePath(const char *, const char *, int *)
Definition: cpl_path.cpp:723
const char CPL_DLL * CPLGetFilename(const char *)
Definition: cpl_path.cpp:230
float CPL_DLL CPLStrtofDelim(const char *, char **, char)
Definition: cpl_strtod.cpp:344
const char CPL_DLL * CPLCleanTrailingSlash(const char *)
Definition: cpl_path.cpp:817
float CPL_DLL CPLStrtof(const char *, char **)
Definition: cpl_strtod.cpp:399
long CPL_DLL CPLScanLong(const char *, int)
Definition: cpl_conv.cpp:821
double CPL_DLL CPLStrtodDelim(const char *, char **, char)
Definition: cpl_strtod.cpp:246
int CPL_DLL CPLUnlinkTree(const char *)
Definition: cpl_conv.cpp:2228
int CPL_DLL CPLCheckForFile(char *pszFilename, char **papszSiblingList)
Definition: cpl_conv.cpp:2456
void CPL_DLL * CPLCalloc(size_t, size_t) CPL_WARN_UNUSED_RESULT
Definition: cpl_conv.cpp:82
void CPL_DLL * CPLScanPointer(const char *, int)
Definition: cpl_conv.cpp:946
void CPL_DLL CPLCloseShared(FILE *)
Definition: cpl_conv.cpp:2087
double CPL_DLL CPLPackedDMSToDec(double)
Definition: cpl_conv.cpp:1898
const char CPL_DLL * CPLResetExtension(const char *, const char *)
Definition: cpl_path.cpp:387
void CPL_DLL * CPLZLibInflate(const void *ptr, size_t nBytes, void *outptr, size_t nOutAvailableBytes, size_t *pnOutBytes)
Uncompress a buffer compressed with ZLib DEFLATE compression.
Definition: cpl_conv.cpp:2537
int CPL_DLL CPLIsFilenameRelative(const char *pszFilename)
Definition: cpl_path.cpp:683
void CPL_DLL * CPLGetSymbol(const char *, const char *)
Definition: cplgetsymbol.cpp:83