[ Index ]
 

Code source de PRADO 3.0.6

Accédez au Source d'autres logiciels libresSoutenez Angelica Josefina !

title

Body

[fermer]

/framework/Web/UI/ -> TPage.php (sommaire)

TPage class file

Author: Qiang Xue <qiang.xue@gmail.com>
Copyright: Copyright © 2005 PradoSoft
License: http://www.pradosoft.com/license/
Version: $Id: TPage.php 1397 2006-09-07 07:55:53Z wei $
Poids: 969 lignes (28 kb)
Inclus ou requis:0 fois
Référencé: 0 fois
Nécessite: 0 fichiers

Définit 2 classes

TPage:: (58 méthodes):
  __construct()
  run()
  processNormalRequest()
  processPostBackRequest()
  processCallbackRequest()
  getForm()
  setForm()
  getValidators()
  validate()
  getIsValid()
  getTheme()
  setTheme()
  getStyleSheetTheme()
  setStyleSheetTheme()
  applyControlSkin()
  applyControlStyleSheet()
  getClientScript()
  onPreInit()
  onInitComplete()
  onPreLoad()
  onLoadComplete()
  onPreRenderComplete()
  getCssMediaType()
  onSaveStateComplete()
  determinePostBackMode()
  getIsPostBack()
  getIsCallback()
  saveState()
  loadState()
  loadPageState()
  savePageState()
  isSystemPostField()
  registerRequiresPostData()
  getPostBackEventTarget()
  setPostBackEventTarget()
  getPostBackEventParameter()
  setPostBackEventParameter()
  processPostData()
  raiseChangedEvents()
  raisePostBackEvent()
  ensureRenderInForm()
  beginFormRender()
  endFormRender()
  setFocus()
  getClientSupportsJavaScript()
  getHead()
  setHead()
  getTitle()
  setTitle()
  getStatePersisterClass()
  setStatePersisterClass()
  getStatePersister()
  getEnableStateValidation()
  setEnableStateValidation()
  getEnableStateEncryption()
  setEnableStateEncryption()
  getPagePath()
  setPagePath()

IPageStatePersister:: (4 méthodes):
  getPage()
  setPage()
  save()
  load()


Classe: TPage  - X-Ref

TPage class

__construct()   X-Ref
Constructor.
Sets the page object to itself.
Derived classes must call parent implementation.


run($writer)   X-Ref
Runs through the page lifecycles.

param: THtmlTextWriter the HTML writer

processNormalRequest($writer)   X-Ref
Pas de description

processPostBackRequest($writer)   X-Ref
Pas de description

processCallbackRequest($writer)   X-Ref
Pas de description

getForm()   X-Ref

return: TForm the form on the page

setForm(TForm $form)   X-Ref
Registers a TForm instance to the page.
Note, a page can contain at most one TForm instance.

param: TForm the form on the page

getValidators($validationGroup=null)   X-Ref
Returns a list of registered validators.
If validation group is specified, only the validators in that group will be returned.

param: string validation group
return: TList registered validators in the requested group. If the group is null, all validators will be returned.

validate($validationGroup=null)   X-Ref
Performs input validation.
This method will invoke the registered validators to perform the actual validation.
If validation group is specified, only the validators in that group will be invoked.

param: string validation group. If null, all validators will perform validation.

getIsValid()   X-Ref
Returns whether user input is valid or not.
This method must be invoked after {@link validate} is called.

return: boolean whether the user input is valid or not.

getTheme()   X-Ref

return: TTheme the theme used for the page. Defaults to null.

setTheme($value)   X-Ref
Sets the theme to be used for the page.

param: string|TTheme the theme name or the theme object to be used for the page.

getStyleSheetTheme()   X-Ref

return: TTheme the stylesheet theme used for the page. Defaults to null.

setStyleSheetTheme($value)   X-Ref
Sets the stylesheet theme to be used for the page.

param: string|TTheme the stylesheet theme name or the stylesheet theme object to be used for the page.

applyControlSkin($control)   X-Ref
Applies a skin in the current theme to a control.
This method should only be used by framework developers.

param: TControl a control to be applied skin with

applyControlStyleSheet($control)   X-Ref
Applies a stylesheet skin in the current theme to a control.
This method should only be used by framework developers.

param: TControl a control to be applied stylesheet skin with

getClientScript()   X-Ref

return: TClientScriptManager client script manager

onPreInit($param)   X-Ref
Raises OnPreInit event.
This method is invoked right before {@link onInit OnInit} stage.
You may override this method to provide additional initialization that
should be done before {@link onInit OnInit} (e.g. setting {@link setTheme Theme} or
{@link setStyleSheetTheme StyleSheetTheme}).
Remember to call the parent implementation to ensure OnPreInit event is raised.

param: mixed event parameter

onInitComplete($param)   X-Ref
Raises OnInitComplete event.
This method is invoked right after {@link onInit OnInit} stage and before {@link onLoad OnLoad} stage.
You may override this method to provide additional initialization that
should be done after {@link onInit OnInit}.
Remember to call the parent implementation to ensure OnInitComplete event is raised.

param: mixed event parameter

onPreLoad($param)   X-Ref
Raises OnPreLoad event.
This method is invoked right before {@link onLoad OnLoad} stage.
You may override this method to provide additional page loading logic that
should be done before {@link onLoad OnLoad}.
Remember to call the parent implementation to ensure OnPreLoad event is raised.

param: mixed event parameter

onLoadComplete($param)   X-Ref
Raises OnLoadComplete event.
This method is invoked right after {@link onLoad OnLoad} stage.
You may override this method to provide additional page loading logic that
should be done after {@link onLoad OnLoad}.
Remember to call the parent implementation to ensure OnLoadComplete event is raised.

param: mixed event parameter

onPreRenderComplete($param)   X-Ref
Raises OnPreRenderComplete event.
This method is invoked right after {@link onPreRender OnPreRender} stage.
You may override this method to provide additional preparation for page rendering
that should be done after {@link onPreRender OnPreRender}.
Remember to call the parent implementation to ensure OnPreRenderComplete event is raised.

param: mixed event parameter

getCssMediaType($url)   X-Ref
Determines the media type of the CSS file.
The media type is determined according to the following file name pattern:
xxx.media-type.extension
For example, 'mystyle.print.css' means its media type is 'print'.

param: string CSS URL
return: string media type of the CSS file

onSaveStateComplete($param)   X-Ref
Raises OnSaveStateComplete event.
This method is invoked right after {@link onSaveState OnSaveState} stage.
You may override this method to provide additional logic after page state is saved.
Remember to call the parent implementation to ensure OnSaveStateComplete event is raised.

param: mixed event parameter

determinePostBackMode()   X-Ref
Determines whether the current page request is a postback.
Call {@link getIsPostBack} to get the result.


getIsPostBack()   X-Ref

return: boolean whether the current page request is a postback

getIsCallback()   X-Ref
TBD

return: boolean whether this is a callback request

saveState()   X-Ref
This method is invoked when control state is to be saved.
You can override this method to do last step state saving.
Parent implementation must be invoked.


loadState()   X-Ref
This method is invoked right after the control has loaded its state.
You can override this method to initialize data from the control state.
Parent implementation must be invoked.


loadPageState()   X-Ref
Loads page state from persistent storage.


savePageState()   X-Ref
Saves page state from persistent storage.


isSystemPostField($field)   X-Ref

param: string the field name
return: boolean whether the specified field is a system field in postback data

registerRequiresPostData(TControl $control)   X-Ref
Registers a control for loading post data in the next postback.
This method needs to be invoked if the control to load post data
may not have a post variable in some cases. For example, a checkbox,
if not checked, will not have a post value.

param: TControl control registered for loading post data

getPostBackEventTarget()   X-Ref

return: TControl the control responsible for the current postback event, null if nonexistent

setPostBackEventTarget(TControl $control)   X-Ref
Registers a control to raise postback event in the current request.

param: TControl control registered to raise postback event.

getPostBackEventParameter()   X-Ref

return: string postback event parameter

setPostBackEventParameter($value)   X-Ref

param: string postback event parameter

processPostData($postData,$beforeLoad)   X-Ref
Processes post data.

param: TMap post data to be processed
param: boolean whether this method is invoked before {@link onLoad OnLoad}.

raiseChangedEvents()   X-Ref
Raises OnPostDataChangedEvent for controls whose data have been changed due to the postback.


raisePostBackEvent()   X-Ref
Raises PostBack event.


ensureRenderInForm($control)   X-Ref
Ensures the control is rendered within a form.

param: TControl the control to be rendered

beginFormRender($writer)   X-Ref


endFormRender($writer)   X-Ref


setFocus($value)   X-Ref
Sets input focus on a control after the page is rendered to users.

param: TControl|string control to receive focus, or the ID of the element on the page to receive focus

getClientSupportsJavaScript()   X-Ref

return: boolean whether client supports javascript. Currently, this

getHead()   X-Ref

return: THead page head, null if not available

setHead(THead $value)   X-Ref

param: THead page head

getTitle()   X-Ref

return: string page title.

setTitle($value)   X-Ref
Sets the page title.
Note, a {@link THead} control needs to place on the page
in order that this title be rendered.

param: string page title. This will override the title set in {@link getHead Head}.

getStatePersisterClass()   X-Ref

return: string class name of the page state persister. Defaults to TPageStatePersister.

setStatePersisterClass($value)   X-Ref

param: string class name of the page state persister.

getStatePersister()   X-Ref

return: IPageStatePersister page state persister

getEnableStateValidation()   X-Ref

return: boolean whether page state should be HMAC validated. Defaults to true.

setEnableStateValidation($value)   X-Ref

param: boolean whether page state should be HMAC validated.

getEnableStateEncryption()   X-Ref

return: boolean whether page state should be encrypted. Defaults to false.

setEnableStateEncryption($value)   X-Ref

param: boolean whether page state should be encrypted.

getPagePath()   X-Ref

return: string the requested page path for this page

setPagePath($value)   X-Ref

param: string the requested page path for this page

Interface: IPageStatePersister  - X-Ref

IPageStatePersister interface.

IPageStatePersister interface is required for all page state persister
classes.

getPage()   X-Ref

param: TPage the page that this persister works for

setPage(TPage $page)   X-Ref

param: TPage the page that this persister works for

save($state)   X-Ref
Saves state to persistent storage.

param: mixed state to be stored

load()   X-Ref
Loads page state from persistent storage

return: mixed the restored state



Généré le : Sun Feb 25 21:07:04 2007 par Balluche grâce à PHPXref 0.7