2 * Worldvisions Weaver Software:
3 * Copyright (C) 1997-2003 Net Integration Technologies, Inc.
5 * Definition of the brains behind the WvDialer class.
9 #ifndef __WVDIALBRAIN_H
10 #define __WVDIALBRAIN_H
17 #include "wvstreamclone.h"
42 WvDialBrain( WvDialer
* a_dialer
);
47 const char * check_prompt( const char * buffer
);
48 const char * guess_menu( char * buf
);
49 int saw_first_compuserve_prompt
;
56 WvString prompt_response
;
58 // These functions are called from check_prompt()....
59 bool is_prompt( const char * c
,
60 const char * promptstring
= NULL
,
61 bool dots_wild
= false );
62 bool is_login_prompt( const char * buf
);
63 bool is_compuserve_prompt( const char * buf
);
64 bool is_password_prompt( const char * buf
);
65 bool is_welcome_msg( const char * buf
);
67 // Menu-string tokenizer....
68 BrainToken
* tokenize( char * left
, char * right
);
69 BrainToken
* tokenize( char * str
);
70 void token_list_done( BrainToken
* token_list
);
72 // Called from guess_menu....
73 void guess_menu_guts( BrainToken
* token_list
);
74 void set_prompt_response( char * str
);
77 inline BrainToken
* WvDialBrain::tokenize( char * str
)
78 /*****************************************************/
83 return( tokenize( str
, str
+strlen( str
) - 1 ) );
86 #endif // __WVDIALBRAIN_H