struct cli_csap_prompts
Overview
A set of possible CLI prompts. More…
#include <tad_cli_impl.h> struct cli_csap_prompts { // fields cli_csap_prompt login; cli_csap_prompt passwd; cli_csap_prompt cmd; };
Detailed Documentation
A set of possible CLI prompts.
Implementation of CLI CSAP uses a separate process in which context functions of Expect library run. Expect library can help waiting for a number of patterns telling us which pattern matches the data read from output. CLI CSAP was designed with an assumption that ‘send’ operations results in some data output that follows with so called COMMAND PROMPT, i.e. a fixed string that tells it is ready to accept the next command. Some commands expect a login/password can be asked in reply, which is why we have two more prompt types: LOGIN PROMPT and PASSWORD PROMPT.
The values for all prompt types can be specified on CSAP creation (command prompt is mandatory), but you can overwrite prompt values for each ‘send’ operation. I.e. if you know that as the result of some command you will get command prompt that differs from original you need to specify new value for command prompt as a part of ‘send’ PDU.
Fields
cli_csap_prompt login
Login prompt
cli_csap_prompt passwd
Password prompt
cli_csap_prompt cmd
Command prompt