SDDSlib
|
Provides functions to prompt the user for various types of numerical input. More...
#include "mdb.h"
Go to the source code of this file.
Functions | |
double | query_double (char *prompt, double def) |
Prompts the user for a double precision number. | |
float | query_float (char *prompt, float def) |
Prompts the user for a float precision number. | |
long | query_long (char *prompt, long def) |
Prompts the user for a long integer. | |
int | query_int (char *prompt, int def) |
Prompts the user for an integer. | |
short | query_short (char *prompt, short def) |
Prompts the user for a short integer. | |
Provides functions to prompt the user for various types of numerical input.
This file contains functions that display prompts to the terminal for different numerical types, show default values, and return the user-entered value or the default if no input is provided.
Definition in file query.c.
double query_double | ( | char * | prompt, |
double | def ) |
Prompts the user for a double precision number.
Displays a prompt with a default value. If the user does not enter a number, the default value is returned.
prompt | The message to display to the user. |
def | The default double value to return if no input is provided. |
Definition at line 32 of file query.c.
float query_float | ( | char * | prompt, |
float | def ) |
Prompts the user for a float precision number.
Displays a prompt with a default value. If the user does not enter a number, the default value is returned.
prompt | The message to display to the user. |
def | The default float value to return if no input is provided. |
Definition at line 54 of file query.c.
int query_int | ( | char * | prompt, |
int | def ) |
Prompts the user for an integer.
Displays a prompt with a default value. If the user does not enter a number, the default value is returned.
prompt | The message to display to the user. |
def | The default integer value to return if no input is provided. |
Definition at line 98 of file query.c.
long query_long | ( | char * | prompt, |
long | def ) |
Prompts the user for a long integer.
Displays a prompt with a default value. If the user does not enter a number, the default value is returned.
prompt | The message to display to the user. |
def | The default long integer value to return if no input is provided. |
Definition at line 76 of file query.c.
short query_short | ( | char * | prompt, |
short | def ) |
Prompts the user for a short integer.
Displays a prompt with a default value. If the user does not enter a number, the default value is returned.
prompt | The message to display to the user. |
def | The default short integer value to return if no input is provided. |
Definition at line 120 of file query.c.