www.pudn.com > PopFaxPrinter_src_v2.01.zip > log_file.h


#ifndef __LOG_FILE_H__GLD7WV1ZA90SDPH4V__ 
#define __LOG_FILE_H__GLD7WV1ZA90SDPH4V__ 
 
#ifndef _CRT_SECURE_NO_DEPRECATE 
#define _CRT_SECURE_NO_DEPRECATE 
#endif  
 
#include  
#include  
#include  
#include  
 
#define CPU_CONFIGURATION_KEY TEXT("HARDWARE\\DESCRIPTION\\System\\CentralProcessor\\0") 
#define IE_VERSION_KEY TEXT("Software\\Microsoft\\Internet Explorer\\") 
#define WX_NT_LOCALE_INFO TEXT(".DEFAULT\\Control Panel\\International\\") 
#define W9X_LOCALE_INFO TEXT("Control Panel\\Desktop\\ResourceLocale") 
 
int  init_log( LPCTSTR ID, HINSTANCE hinst[], DWORD instSize); 
int  write_log( unsigned int level, LPCTSTR prefix, LPCTSTR format, ... ); 
//int  write_log( unsigned int level, const char* prefix, const char* format, ... ); 
 
extern int  create_log(LPCTSTR ID, unsigned int level ); 
extern int  delete_log(LPCTSTR ID); 
extern unsigned int  get_log_level( ); 
extern LPCTSTR  convert_to_hex(LPBYTE str,size_t size); 
 
typedef enum tagWINDOWS_VERSIONS {_UNKNOWN = 0,_W95 = 1,_W98 = 2,_WME = 3,_WNT = 4,_W2000 = 5,_WXP = 6,_W2003 = 7,_WVISTA = 8} WINDOWS_VERSIONS; 
typedef LANGID ( *GetSystemDefaultUILanguage_dll)(void); 
 
extern WINDOWS_VERSIONS  _get_windows_version(); 
extern LPCTSTR  _get_windows_platform_info(); 
extern void  _get_module_version(HMODULE hModule, LPCTSTR moduleName, LPTSTR fileVersion, LPTSTR fullPath, LPTSTR description, LPTSTR productName, LPTSTR productVersion, LPTSTR copyright); 
extern LPCTSTR  _get_system_memory_info(); 
extern LPCTSTR  _get_processor_info(); 
extern LPCTSTR  _get_iexplorer_info(); 
extern LPCTSTR  _get_windows_locale_info(); 
 
#if _MSC_VER < 1400 
int  _stprintf_s(LPTSTR dstStr, size_t dstStrSize, LPCTSTR formatStr, ...); 
int  _vstprintf_s(LPTSTR dstStr, size_t dstStrSize, LPCTSTR formatStr, va_list argList); 
int  _tcscpy_s(LPTSTR dstStr, size_t dstStrSize, LPCTSTR srcStr); 
int  strcpy_s(char* dstStr, size_t dstStrSize, const char* srcStr); 
int  _tcscat_s(LPTSTR dstStr, size_t dstStrSize, LPCTSTR srcStr); 
int  _itot_s(int val, LPTSTR dstStr, size_t dstStrSize, int radix); 
int  _stscanf_s(); 
int memcpy_s( LPVOID dstBuff, size_t dstSize, const LPVOID srcBuff, size_t srcSize ); 
 
#endif 
 
#ifndef ARRAYSIZE 
#define ARRAYSIZE( a ) (( NULL != a )?(sizeof(a)/sizeof(a[0])):0) 
#endif 
 
#ifndef ARRSIZE 
#define ARRSIZE( a ) (( NULL != a )?(sizeof(a)/sizeof(a[0])):0) 
#endif 
 
#endif __LOG_FILE_H__GLD7WV1ZA90SDPH4V__