blob: b83f61ef35a318ce545a3b22827e46e95959391e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
|
#if defined(OS400) && (__OS400_TGTVRM__ >= 510)
#pragma datamodel(P128)
#endif
/*********************************************************************/
/* */
/* Licensed Materials - Property of IBM */
/* */
/* L-GHUS-5VMPGW, L-GHUS-5S3PEE */
/* (C) Copyright IBM Corp. 1991, 2004 All Rights Reserved */
/* */
/* US Government Users Restricted Rights - Use, duplication or */
/* disclosure restricted by GSA ADP Schedule Contract with */
/* IBM Corp. */
/* */
/*********************************************************************/
#ifndef ENV_DEFS
#define ENV_DEFS
#ifdef __cplusplus
extern "C" {
#endif
/* Size of the buffer used to hold the environment variable values (i.e., it
excludes the variable name) but including the trailing null terminator.
NOTE: The largest known example of an environment variable value is a
max'ed out COMx=... (the modem init strings can be large, and
there's plenty of them).
*/
#define MAXENVVALUE 256
/* Used to preface ini variables that are different between OSs which may */
/* share the same INI file. */
#if defined(PM)
#define OS_PREFIX "PM"
#elif defined(W)
#define OS_PREFIX "WIN"
#else
#define OS_PREFIX "" /* Only necessary to distinguish */
/* between entries used in a multi */
/* OS environment with a single NOTES.INI */
#endif
/* Environment variable package */
#define NATIVE "Native"
/* System temp directory constants */
#define TEMP_DIR_PREFIX "notes"
#define TEMP_DIR_SUFFIX_LEN 6 /* If changing, must change TEMP_DIR_SUFFIX_FORMATSPEC to match */
#define TEMP_DIR_SUFFIX_FORMATSPEC "%06x"
#define TEMP_DIR_DEFAULT_SUFFIX "G00000"
#define TEMP_DIR_SUFFIX_MAX_VALUE 0x00FFFFFF
BOOL LNPUBLIC OSGetEnvironmentString (const char far *VariableName, char far *retValueBuffer, WORD BufferLength);
long LNPUBLIC OSGetEnvironmentLong (const char far *VariableName);
#define OSGetEnvironmentInt(s) ((int) OSGetEnvironmentLong(s))
void LNPUBLIC OSSetEnvironmentVariable (const char far *VariableName, const char far *Value);
void LNPUBLIC OSSetEnvironmentInt (const char far *VariableName, int Value);
#ifdef __cplusplus
}
#endif
#endif
#if defined(OS400) && (__OS400_TGTVRM__ >= 510)
#pragma datamodel(pop)
#endif
|