5 Copyright © 1995-2001, The AROS Development Team. All rights reserved.
8 Desc: Environment variable handling.
13 # include <exec/nodes.h>
16 /* This structure describes a local variable. The list is normally held in
17 Process->pr_LocalVars. See <dos/dosextens.h> for more information about
18 the list. Note that this structure is READ-ONLY! Allocate it with SetVar().
21 struct Node lv_Node
; /* Standard node structure as defined in
22 <exec/nodes.h>. See also below. */
24 UBYTE
* lv_Value
; /* The contents of the variable. */
25 ULONG lv_Len
; /* The length of the contents. */
28 /* This structure is used by ScanVars() function to pass information about
29 local and/or global variables to specified hook function. Note that this
30 structure is READ-ONLY and its content is valid only during ScanVars()
31 hook function call. Don't try to use a pointer to this structure outside
32 ScanVars() hook function.
36 ULONG sv_SVMSize
; /* Size of ScanVarsMsg structure */
37 ULONG sv_Flags
; /* The flags parameter given to ScanVars() */
38 STRPTR sv_GDir
; /* Directory patch for global variables or empty string
39 "\0" for local variables */
40 STRPTR sv_Name
; /* Name of the variable */
41 STRPTR sv_Var
; /* Pointer to the contents of the variable */
42 ULONG sv_VarLen
; /* Size of the variable */
46 #define LV_VAR 0 /* This is a variable. */
47 #define LV_ALIAS 1 /* This is an alias. */
48 /* This flag may be or'ed into lv_Node.ln_Type. It means that dos.library
49 should ignore this entry. */
51 #define LVF_IGNORE (1L<<LVB_IGNORE)
53 /* The following flags are used as flags for the dos variable functions.
54 GVB_BINARY_VAR and GVB_DONT_NULL_TERM are also saved in lv_Flags.
56 /* The variable is not to be used locally. */
57 #define GVB_GLOBAL_ONLY 8
58 /* The variable is not to be used globally. */
59 #define GVB_LOCAL_ONLY 9
60 /* The variable is a binary variable. lv_Value points to binary data. */
61 #define GVB_BINARY_VAR 10
62 /* lv_Value is not null-terminated. This is only allowed, if GVB_BINARY_VAR
64 #define GVB_DONT_NULL_TERM 11
65 /* This flag tells dos to save the variable to ENVARC: too. */
66 #define GVB_SAVE_VAR 12
68 #define GVF_GLOBAL_ONLY (1L<<GVB_GLOBAL_ONLY)
69 #define GVF_LOCAL_ONLY (1L<<GVB_LOCAL_ONLY)
70 #define GVF_BINARY_VAR (1L<<GVB_BINARY_VAR)
71 #define GVF_DONT_NULL_TERM (1L<<GVB_DONT_NULL_TERM)
72 #define GVF_SAVE_VAR (1L<<GVB_SAVE_VAR)
74 #endif /* DOS_VAR_H */