BOOTSTRAP (kutils) functions
LIBRARY ROUTINE
kprompt - request an acknowledgement from the user
LIBRARY CALL
int kprompt(
int notify_type,
char *yes_response,
char *no_response,
int default_val,
char *format,
kvalist)
INPUT
- notify_type - the notify level specified by the programmer
KFORCE, KSTANDARD, KVERBOSSE
- yes_response - name of "yes" response string ("Yes" if NULL)
- no_response - name of "no" response string ("No" if NULL)
- default_val - the default value to list when prompting
- format - grammatically correct, clear explanation of
the error that occurred. This can be formatted
like a printf statement.
OUTPUT
none
RETURN VALUE
TRUE if the prompt was successfully acknowledged,
otherwise if the message was not acknowledged FALSE
is returned. In the event and error occurs the
default value is returned.
DESCRIPTION
kprompt will call the specified prompt handler to request
or demand an acknowledgement from the user. This utility
can operate in several different modes.
If the notify_type variable is set to KFORCE, then the
prompt will always appear regardless of the setting
of the environment variable KHOROS_NOTIFY.
If the notify_type variable is set to KSTANDARD and the
user has the environment variable KHOROS_NOTIFY set to
either STANDARD or VERBOSE the prompt will appear.
And finally, if the notify_type variable is set to KVERBOSE
and the environment variable KHOROS_NOTIFY set to VERBOSE,
the prompt will appear.
Here is a summary table:
notify_type = FORCE always prompt, ignore the setting of
the environment variable KHOROS_NOTIFY
notify_type = STANDARD only prompt when the environment
variable KHOROS_NOTIFY is set to
STANDARD or VERBOSE.
notify_type = VERBOSE only prompt when the environment
variable KHOROS_NOTIFY is set to
VERBOSE
ADDITIONAL INFORMATION
none
EXAMPLES
none
SIDE EFFECTS
none
RESTRICTIONS
none
MODIFICATION
none
FILES
$BOOTSTRAP/objects/library/kutils/src/notify.c
SEE ALSO
kutils(3)
COPYRIGHT
Copyright (C) 1993 - 1997, Khoral Research, Inc. ("KRI") All rights reserved.