Path

ez components / documentation / api reference / 2009.1.1 / consoletools


eZ Components 2009.1.1

ConsoleTools: ezcConsoleDialog

[ Tutorial ] [ Class tree ] [ Element index ] [ ChangeLog ] [ Credits ]

Interface: ezcConsoleDialog

Interface that every console dialog class must implement. [source]
Console dialogs can either be used on their own or using the ezcConsoleDialogViewer (recommended). In the dialog viewer, a dialog is instanciated and displayed in a loop, until it receives a valid result value.

Method Summary

public void display( )
Displays the dialog.
public mixed getResult( )
Returns the result retrieved.
public bool hasValidResult( )
Returns if the dialog retrieved a valid result.
public void reset( )
Resets the dialog to its initial state.

Methods

display

void display( )
Displays the dialog.
Displays the dialog. Dialogs will most propably block the application until the user took some interaction.

getResult

mixed getResult( )
Returns the result retrieved.
If no valid result was retreived, yet, this method should throw an ezcDialogNoValidResultException. Otherwise this method returns the result.

Throws

ClassDescription
ezcDialogNoValidResultException if this method is called without a valid result being retrieved by the object. Use hasValidResult() to avoid this exception.

hasValidResult

bool hasValidResult( )
Returns if the dialog retrieved a valid result.
Typically a dialog is displayed in a loop until he received a valid result. What a valid result is, is determined by the dialog itself.

reset

void reset( )
Resets the dialog to its initial state.
Resets the dialog to its orginal state in respect to its internal changes. Note: Any changes you made to the options are kept in tact.

Last updated: Mon, 27 Jul 2009