Path

ez components / documentation / api reference / latest / consoletools


eZ Components latest

ConsoleTools: ezcConsoleDialogViewer

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

Class: ezcConsoleDialogViewer

Utility class for ezcConsoleDialog implementations. [source]
This class contains utility methods for working with ezcConsoleDialog implementations.
To display a dialog in a loop until a valid result is received do:
1.  // Instatiate dialog in $dialog ...
2.   ezcConsoleDialogViewer::displayDialog$dialog );
For implementing a custom dialog, the method readLine() method can be used to read a line of input from the user.

Method Summary

public static mixed displayDialog( $dialog )
Displays a dialog and returns a valid result from it.
public static string readLine( )
Returns a line from STDIN.

Methods

displayDialog

mixed displayDialog( ezcConsoleDialog $dialog )
Displays a dialog and returns a valid result from it.
This methods displays a dialog in a loop, until it received a valid result from it and returns this result.

Parameters

Name Type Description
$dialog ezcConsoleDialog The dialog to display.

readLine

string readLine( )
Returns a line from STDIN.
The returned line is fully trimmed.

Last updated: Tue, 02 Dec 2008