UI_new

- NAME
- SYNOPSIS
- DESCRIPTION
- NOTES
- COPYRIGHT

# NAME

UI, UI_new, UI_new_method, UI_free, UI_add_input_string, UI_dup_input_string, UI_add_verify_string, UI_dup_verify_string, UI_add_input_boolean, UI_dup_input_boolean, UI_add_info_string, UI_dup_info_string, UI_add_error_string, UI_dup_error_string, UI_construct_prompt, UI_add_user_data, UI_get0_user_data, UI_get0_result, UI_process, UI_ctrl, UI_set_default_method, UI_get_default_method, UI_get_method, UI_set_method, UI_OpenSSL, UI_null - user interface

# SYNOPSIS

     #include <openssl/ui.h>

     typedef struct ui_st UI;

     UI *UI_new(void);
     UI *UI_new_method(const UI_METHOD *method);
     void UI_free(UI *ui);

     int UI_add_input_string(UI *ui, const char *prompt, int flags,
            char *result_buf, int minsize, int maxsize);
     int UI_dup_input_string(UI *ui, const char *prompt, int flags,
            char *result_buf, int minsize, int maxsize);
     int UI_add_verify_string(UI *ui, const char *prompt, int flags,
            char *result_buf, int minsize, int maxsize, const char *test_buf);
     int UI_dup_verify_string(UI *ui, const char *prompt, int flags,
            char *result_buf, int minsize, int maxsize, const char *test_buf);
     int UI_add_input_boolean(UI *ui, const char *prompt, const char *action_desc,
            const char *ok_chars, const char *cancel_chars,
            int flags, char *result_buf);
     int UI_dup_input_boolean(UI *ui, const char *prompt, const char *action_desc,
            const char *ok_chars, const char *cancel_chars,
            int flags, char *result_buf);
     int UI_add_info_string(UI *ui, const char *text);
     int UI_dup_info_string(UI *ui, const char *text);
     int UI_add_error_string(UI *ui, const char *text);
     int UI_dup_error_string(UI *ui, const char *text);

     char *UI_construct_prompt(UI *ui_method,
            const char *object_desc, const char *object_name);

     void *UI_add_user_data(UI *ui, void *user_data);
     void *UI_get0_user_data(UI *ui);

     const char *UI_get0_result(UI *ui, int i);

     int UI_process(UI *ui);

     int UI_ctrl(UI *ui, int cmd, long i, void *p, void (*f)());

     void UI_set_default_method(const UI_METHOD *meth);
     const UI_METHOD *UI_get_default_method(void);
     const UI_METHOD *UI_get_method(UI *ui);
     const UI_METHOD *UI_set_method(UI *ui, const UI_METHOD *meth);

     UI_METHOD *UI_OpenSSL(void);
     const UI_METHOD *UI_null(void);

# DESCRIPTION

UI stands for User Interface, and is general purpose set of routines to prompt the user for text-based information. Through user-written methods (see NOTES

The resulting strings that the built in method UI_OpenSSL() generate are assumed to be encoded according to the current locale or (for Windows) code page. For applications having different demands, these strings need to be converted appropriately by the caller. For Windows, if the OPENSSL_WIN32_UTF8 environment variable is set, the built-in method UI_OpenSSL() will produce UTF-8 encoded strings instead.

# COPYRIGHT

Copyright 2001-2017 The OpenSSL Project Authors. All Rights Reserved.

Licensed under the OpenSSL license (the "License"). You may not use this file except in compliance with the License. You can obtain a copy in the file LICENSE in the source distribution or at https://www.openssl.org/source/license.html.