src/include/common/base/fscapi.h

00001 /*
00002  * Copyright (C) 2003-2007 Funambol
00003  *
00004  * This program is free software; you can redistribute it and/or modify
00005  * it under the terms of the GNU General Public License as published by
00006  * the Free Software Foundation; either version 2 of the License, or
00007  * (at your option) any later version.
00008  *
00009  * This program is distributed in the hope that it will be useful,
00010  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00011  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00012  * GNU General Public License for more details.
00013  *
00014  * You should have received a copy of the GNU General Public License
00015  * along with this program; if not, write to the Free Software
00016  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00017  */
00018 
00027 #ifndef INCL_FSCAPI
00028     #define INCL_FSCAPI
00029 
00031     #ifdef AUTOTOOLS
00032         #include "base/posixadapter.h"
00033     #endif
00034     #ifdef HAVE_STDARG_H
00035         #include <stdarg.h>
00036     #endif
00037 
00038     #include "base/errors.h"
00039 
00040     #if defined(_WIN32_WCE) || defined(WIN32)
00041         // Insert your headers here
00042         #define WIN32_LEAN_AND_MEAN     // Exclude rarely-used stuff from Windows headers
00043 
00044         #include <windows.h>
00045     #endif
00046     
00047     #if defined(WIN32) 
00048         #include "wininet.h"
00049     #endif
00050 
00051     #if defined(WIN32) && !defined(_WIN32_WCE)
00052         #include <wchar.h>
00053         #include <time.h>
00054         #include <stdlib.h>
00055         #include "base/win32adapter.h" 
00056     #endif
00057 
00058     #ifdef _WIN32_WCE
00059         #include "base/time.h"
00060         #include "base/winmobileadapter.h" 
00061     #endif
00062 
00063     #if defined(__PALMOS__)
00064       #include "base/palmadapter.h"
00065     #endif
00066 
00067     #ifdef MALLOC_DEBUG
00068       #pragma warning(disable:4291)
00069       extern size_t dbgcounter;
00070       void *operator new(size_t s);
00071       void *operator new[](size_t s);
00072       void *operator new(size_t s, char* file, int line);
00073       void *operator new[](size_t s, char* file, int line);
00074       void operator delete(void* p);
00075       void operator delete[] (void* p);
00076 
00077       #define new new(__FILE__, __LINE__)
00078     #endif
00079     
00080     extern char lastErrorMsg[];
00081     extern int  lastErrorCode;
00082 
00083     void resetError();
00084 
00085     #ifndef SYNC4J_LINEBREAK
00086     // default encoding of line break in native strings,
00087     // may be overridden by adapter header files above
00088     # define SYNC4J_LINEBREAK TEXT("\r\n")
00089     #endif
00090 
00091     #ifndef WCHAR_PRINTF
00092 
00093     # define WCHAR_PRINTF "ls"
00094     #endif
00095 
00112     #include <assert.h>
00113     
00115 #endif
00116 
00117 

Generated on Fri Apr 27 12:29:18 2007 for Funambol C++ Client Library by  doxygen 1.5.2