31 #include <sys/types.h>
33 #ifndef __wenv_internal
34 #include <ldb/wenv_stubs.h>
47 #define WE_DATA_ENV "DATA"
48 #define WE_JOBS_ENV "JOB"
49 #define WE_LOGS_ENV "LOG"
50 #define WE_LOCKS_ENV "LOCKS"
51 #define WE_HCOPIES_ENV "HCOPIES"
52 #define WE_REPORT_ENV "REPORT"
53 #define WE_ARCHIVE_ENV "ARCHIVE"
60 #define WE_DELIVER_JOBNUM_PREFIX "DELIVER_JOBNUM_"
65 #define weVersion() VERSION_NUMBER
67 #define weVersion() (-1)
73 #define WE_NAME_LEN 99
76 #define WE_MSG_LEN 2047
98 #define WE_LANG_ENGLISH "en"
99 #define WE_LANG_RUSSIAN "ru"
100 #define WE_LANG_CHINESE "cn"
104 #define WE_LANG_FILENAME "language"
118 void weSetProduct (
int);
122 void weInitialize ();
126 void weSetAppName (
const char* szAppName);
129 const char* weAppName ();
132 const char* weHostName ();
136 pid_t weAppInstance ();
141 const char* weWorkplaceName ();
144 const char* weUserName ();
163 const char* weSystemLoc ();
166 const char* weUserLoc ();
171 int weCheckStdAppEnv ();
178 int weDeliverJobNumber (
const char* szApplication,
int nJob);
181 void weDeliverJobNumberName (
const char* szApplication,
191 void weSystemAtExitHandler ();
194 typedef void (*weAtExitHandlerProc)(void);
197 void weRegisterAtExitHandler (weAtExitHandlerProc proc);
201 void weUnregisterAtExitHandler (weAtExitHandlerProc proc);
210 void wePutMsg (
int elevel,
const char* msg);
213 void weFormatMsg (
int elevel,
const char* format, ...);
217 typedef int (*weMsgHandlerProc)(
int elevel,
const char* msg);
221 void weRegisterMsgHandler (weMsgHandlerProc proc);
227 int weExtendedMsgHandlerProc (
int elevel,
const char* msg);
238 char* weMoment (
char* place);
243 char* weFormatTime (
char* place,
struct tm* tm_ptr);
248 char* weFormatDate (
char* place,
struct tm* tm_ptr);
252 int weParseMoment (
const char* szMoment,
struct tm* tm_ptr);
253 int weParseDate (
const char* szDate,
struct tm* tm_ptr);
254 int weParseTime (
const char* szTime,
struct tm* tm_ptr);
263 char* weGetPrefLanguage ();
266 void weSetPrefLanguage (
const char* szLang);
285 int weDevelopLevel ();