PHP Class Prado\Web\UI\ActiveControls\TCallback

The TCallback provides a basic callback handler that can be invoked from the client side by running the javascript code obtained from the {@link TBaseActiveCallbackControl::getJavascript ActiveControl.Javascript} property. The event {@link onCallback OnCallback} is raised when a callback is requested made. Example usage:
Click Me!
Since: 3.1
Inheritance: extends Prado\Web\UI\TControl, implements Prado\Web\UI\ActiveControls\ICallbackEventHandler, implements Prado\Web\UI\ActiveControls\IActiveControl
Mostrar archivo Open project: pradosoft/prado Class Usage Examples

Public Methods

Method Description
__construct ( ) Creates a new callback control, sets the adapter to TActiveControlAdapter. If you override this class, be sure to set the adapter appropriately by, for example, call this constructor.
getActiveControl ( ) : TBaseActiveCallbackControl
getClientSide ( ) : TCallbackClientSide
onCallback ( $param ) This method is invoked when a callback is requested. The method raises 'OnCallback' event to fire up the event handlers. If you override this method, be sure to call the parent implementation so that the event handler can be invoked.
raiseCallbackEvent ( $param ) Raises the callback event. This method is required by {@link ICallbackEventHandler ICallbackEventHandler} interface. If {@link getCausesValidation ActiveControl.CausesValidation} is true, it will invoke the page's {@link TPage::validate validate} method first.

Method Details

__construct() public method

Creates a new callback control, sets the adapter to TActiveControlAdapter. If you override this class, be sure to set the adapter appropriately by, for example, call this constructor.
public __construct ( )

getActiveControl() public method

public getActiveControl ( ) : TBaseActiveCallbackControl
return TBaseActiveCallbackControl standard callback options.

getClientSide() public method

public getClientSide ( ) : TCallbackClientSide
return TCallbackClientSide client side request options.

onCallback() public method

This method is invoked when a callback is requested. The method raises 'OnCallback' event to fire up the event handlers. If you override this method, be sure to call the parent implementation so that the event handler can be invoked.
public onCallback ( $param )

raiseCallbackEvent() public method

It will raise {@link onCallback OnCallback} event. This method is mainly used by framework and control developers.
public raiseCallbackEvent ( $param )