#include <YUIComponent.h>
Inheritance diagram for YUIComponent:
Public Member Functions | |
void | createUI () |
YCPValue | callBuiltin (void *function, int fn_argc, YCPValue fn_argv[]) |
void | result (const YCPValue &result) |
void | setServerOptions (int argc, char **argv) |
virtual string | name () const |
void | setCallback (Y2Component *callback) |
Y2Component * | getCallback () const |
Static Public Member Functions | |
static YUIComponent * | uiComponent () |
static YUI * | ui () |
Protected Member Functions | |
YUIComponent () | |
virtual | ~YUIComponent () |
virtual YUI * | createUI (int argc, char **argv, bool with_threads, const char *macro_file)=0 |
Private Attributes | |
int | _argc |
char ** | _argv |
const char * | _macro_file |
bool | _with_threads |
bool | _have_server_options |
Static Private Attributes | |
static YUI * | _ui = 0 |
static YUIComponent * | _uiComponent = 0 |
|
Constructor. |
|
Destructor. |
|
YUIComponent level call handler; this creates the actual UI instance upon its first call and then hands over the function to be called to the UI's call handler. Weird, huh? ;-) |
|
Create a UI instance. The UI component normally handles that all by itself when the first UI builtin is called, but under very rare circumstances (e.g., in kyast) the UI needs to be created upon demand. |
|
Create the UI. This is called when all the information for doing that is complete, in setServerOptions(). 'argc' and 'argv' are the command line arguments. Implement this method in derived classes. |
|
Returns the UI's callback component previously set with setCallback(); calls the UI's getCallback() method. |
|
The name of the component - the prefix used for builtin calls like UI::OpenDialog() etc. Implements Y2Component. |
|
Called from generic frontend upon session close. This deletes the UI. Reimplemented from Y2Component. |
|
Set a callback component - call the UI's setCallback() method. |
|
This is called by the generic frontend after it parsed the commandline. This actually creates an UI instance with createUI(). Reimplemented from Y2Component. |
|
Returns the instance of the UI or 0 if none has been created yet. Note: This does _not_ create a UI on the first call; this happens in the first call of a UI builtin via the YUIComponent's call handler which creates a UI upon its first call and then calls the UI's call handler. |
|
Returns the instance of the UI component 0 if none has been created yet. |
|
|
|
|
|
|
|
|
|
|
|
|
|
|