Index

Classes

  • TAPCCache
  • TApplicationStateCacheDependency
  • TCache
  • TCacheDependency
  • TCacheDependencyList
  • TChainedCacheDependency
  • TDbCache
  • TDirectoryCacheDependency
  • TEtcdCache
  • TFileCacheDependency
  • TGlobalStateCacheDependency
  • TMemCache
  • TRedisCache
  • TArraySubscription
  • TAttributeCollection
  • TCollectionSubscription
  • TDummyDataSource
  • TDummyDataSourceIterator
  • TList
  • TListItemCollection
  • TMap
  • TPagedDataSource
  • TPagedList
  • TPagedListFetchDataEventParameter
  • TPagedListIterator
  • TPagedListPageChangedEventParameter
  • TPagedMapIterator
  • TPriorityList
  • TPriorityMap
  • TQueue
  • TQueueIterator
  • TStack
  • TWeakCallableCollection
  • TWeakList
  • TActiveRecordConfigurationException
  • TActiveRecordException
  • TActiveRecordBelongsTo
  • TActiveRecordHasMany
  • TActiveRecordHasManyAssociation
  • TActiveRecordHasOne
  • TActiveRecordRelation
  • TActiveRecordRelationContext
  • TIbmScaffoldInput
  • TMssqlScaffoldInput
  • TMysqlScaffoldInput
  • TPgsqlScaffoldInput
  • TScaffoldInputBase
  • TScaffoldInputCommon
  • TSqliteScaffoldInput
  • TScaffoldBase
  • TScaffoldEditView
  • TScaffoldListView
  • TScaffoldSearch
  • TScaffoldView
  • TActiveRecord
  • TActiveRecordChangeEventParameter
  • TActiveRecordConfig
  • TActiveRecordCriteria
  • TActiveRecordGateway
  • TActiveRecordInvalidFinderResult
  • TActiveRecordManager
  • TMssqlCommandBuilder
  • TMssqlMetaData
  • TMssqlTableColumn
  • TMssqlTableInfo
  • TMysqlCommandBuilder
  • TMysqlMetaData
  • TMysqlTableColumn
  • TMysqlTableInfo
  • TOracleCommandBuilder
  • TOracleMetaData
  • TOracleTableColumn
  • TOracleTableInfo
  • TPgsqlCommandBuilder
  • TPgsqlMetaData
  • TPgsqlTableColumn
  • TPgsqlTableInfo
  • TSqliteCommandBuilder
  • TSqliteMetaData
  • TSqliteTableColumn
  • TSqliteTableInfo
  • TDbCommandBuilder
  • TDbMetaData
  • TDbTableColumn
  • TDbTableInfo
  • TDataGatewayCommand
  • TDataGatewayEventParameter
  • TDataGatewayResultEventParameter
  • TSqlCriteria
  • TTableGateway
  • TDiscriminator
  • TInlineParameterMapParser
  • TParameterMap
  • TParameterProperty
  • TResultMap
  • TResultProperty
  • TSimpleDynamicParser
  • TSqlMapCacheKey
  • TSqlMapCacheModel
  • TSqlMapCacheTypes
  • TSqlMapDelete
  • TSqlMapInsert
  • TSqlMapSelect
  • TSqlMapSelectKey
  • TSqlMapStatement
  • TSqlMapUpdate
  • TSqlMapXmlConfigBuilder
  • TSqlMapXmlConfiguration
  • TSqlMapXmlMappingConfiguration
  • TSubMap
  • TInvalidPropertyException
  • TLazyLoadList
  • TObjectProxy
  • TPropertyAccess
  • TSqlMapApplicationCache
  • TSqlMapCache
  • TSqlMapConfigurationException
  • TSqlMapDuplicateException
  • TSqlMapException
  • TSqlMapExecutionException
  • TSqlMapFifoCache
  • TSqlMapLruCache
  • TSqlMapPagedList
  • TSqlMapTypeHandler
  • TSqlMapTypeHandlerRegistry
  • TSqlMapUndefinedException
  • TCachingStatement
  • TDeleteMappedStatement
  • TInsertMappedStatement
  • TMappedStatement
  • TPostSelectBinding
  • TPreparedCommand
  • TPreparedStatement
  • TPreparedStatementFactory
  • TResultSetListItemParameter
  • TResultSetMapItemParameter
  • TSelectMappedStatement
  • TSimpleDynamicSql
  • TSqlMapObjectCollectionTree
  • TStaticSql
  • TUpdateMappedStatement
  • TSqlMapConfig
  • TSqlMapGateway
  • TSqlMapManager
  • TDataSourceConfig
  • TDbColumnCaseMode
  • TDbCommand
  • TDbConnection
  • TDbDataReader
  • TDbNullConversionMode
  • TDbTransaction
  • TApplicationException
  • TConfigurationException
  • TDbConnectionException
  • TDbException
  • TErrorHandler
  • TException
  • TExitException
  • THttpException
  • TInvalidDataTypeException
  • TInvalidDataValueException
  • TInvalidOperationException
  • TIOException
  • TLogException
  • TNetworkException
  • TNotSupportedException
  • TPhpErrorException
  • TPhpFatalErrorException
  • TSocketException
  • TSystemException
  • TTemplateException
  • TUnknownMethodException
  • TUserException
  • ChoiceFormat
  • CultureInfo
  • TGettext
  • TGettext_MO
  • TGettext_PO
  • MessageCache
  • MessageFormat
  • MessageSource
  • MessageSource_Database
  • MessageSource_gettext
  • MessageSource_PHP
  • MessageSource_XLIFF
  • TCache_Lite
  • TMessageSourceIOException
  • TChoiceFormat
  • TDateFormat
  • TGlobalization
  • TGlobalizationAutoDetect
  • TI18NControl
  • TNumberFormat
  • Translation
  • TTranslate
  • TTranslateParameter
  • TOutputWriter
  • TStdOutWriter
  • TStreamNotificationCallback
  • TStreamNotificationParameter
  • TTarFileExtractor
  • TTextWriter
  • DynamicMethodReflection
  • DynamicMethodsClassReflectionExtension
  • Prado
  • TPermissionEvent
  • TPermissionsAction
  • TPermissionsBehavior
  • TPermissionsConfigurationBehavior
  • TPermissionsManager
  • TUserOwnerRule
  • TUserPermissionsBehavior
  • TAuthManager
  • TAuthorizationRule
  • TAuthorizationRuleCollection
  • TDbUser
  • TDbUserManager
  • TSecurityManager
  • TUser
  • TUserManager
  • TUserManagerPasswordMode
  • TActiveRecordAction
  • TDbParameterAction
  • TFlushCachesAction
  • THelpAction
  • TPhpShellAction
  • TWebServerAction
  • TShellAction
  • TShellApplication
  • TShellLoginBehavior
  • TShellWriter
  • TApplication
  • TApplicationComponent
  • TApplicationConfiguration
  • TApplicationMode
  • TApplicationStatePersister
  • TComponent
  • TComponentReflection
  • TEnumerable
  • TEventHandler
  • TEventParameter
  • TEventResults
  • TEventSubscription
  • TModule
  • TPropertyValue
  • TService
  • TApplicationSignals
  • TBehaviorParameterLoader
  • TCaptureForkLog
  • TForkable
  • TGlobalClassAware
  • TMapLazyLoadBehavior
  • TMapRouteBehavior
  • TPageGlobalizationCharsetBehavior
  • TPageNoCacheBehavior
  • TPageTopAnchorBehavior
  • TParameterizeBehavior
  • TTimeZoneParameterBehavior
  • TCronMethodTask
  • TCronModule
  • TCronTask
  • TCronTaskInfo
  • TDbCronCleanLogTask
  • TDbCronModule
  • TShellCronAction
  • TShellCronLogBehavior
  • TShellDbCronAction
  • TTimeScheduler
  • TArrayHelper
  • TBitHelper
  • TEscCharsetConverter
  • TProcessHelper
  • TProcessWindowsPriority
  • TProcessWindowsPriorityName
  • TRational
  • TURational
  • TBaseBehavior
  • TBehavior
  • TBehaviorsModule
  • TBrowserLogRoute
  • TCallChain
  • TClassBehavior
  • TClassBehaviorEventParameter
  • TDataFieldAccessor
  • TDbLogRoute
  • TDbParameterModule
  • TDbPluginModule
  • TEmailLogRoute
  • TFileLogRoute
  • TFirebugLogRoute
  • TFirePhpLogRoute
  • TJsonRpcClient
  • TLogger
  • TLogRoute
  • TLogRouter
  • TParameterModule
  • TPluginModule
  • TRpcClient
  • TRpcClientRequestException
  • TRpcClientResponseException
  • TRpcClientTypesEnumerable
  • TSignalParameter
  • TSignalsDispatcher
  • TSimpleDateFormatter
  • TStdOutLogRoute
  • TSysLogRoute
  • TUtf8Converter
  • TVarDumper
  • TXmlRpcClient
  • TRequestConnectionUpgrade
  • TJavaScript
  • TJavaScriptAsset
  • TJavaScriptLiteral
  • TJavaScriptString
  • TFeedService
  • TJsonResponse
  • TJsonRpcProtocol
  • TJsonService
  • TPageConfiguration
  • TPageService
  • TRpcApiProvider
  • TRpcException
  • TRpcProtocol
  • TRpcServer
  • TRpcService
  • TSoapServer
  • TSoapService
  • TXmlRpcProtocol
  • TAssetManager
  • TCacheHttpSession
  • THttpCookie
  • THttpCookieCollection
  • THttpCookieSameSite
  • THttpRequest
  • THttpRequestParameter
  • THttpRequestResolveMethod
  • THttpRequestUrlFormat
  • THttpResponse
  • THttpResponseAdapter
  • THttpSession
  • THttpSessionCookieMode
  • THttpUtility
  • TSessionIterator
  • TUri
  • TUrlManager
  • TUrlMapping
  • TUrlMappingPattern
  • TUrlMappingPatternSecureConnection
  • TActiveBoundColumn
  • TActiveButton
  • TActiveButtonColumn
  • TActiveCheckBox
  • TActiveCheckBoxColumn
  • TActiveCheckBoxList
  • TActiveCheckBoxListItem
  • TActiveClientScript
  • TActiveControlAdapter
  • TActiveCustomValidator
  • TActiveCustomValidatorClientSide
  • TActiveDataGrid
  • TActiveDataGridPager
  • TActiveDataGridPagerEventParameter
  • TActiveDataList
  • TActiveDatePicker
  • TActiveDatePickerClientScript
  • TActiveDropDownList
  • TActiveDropDownListColumn
  • TActiveEditCommandColumn
  • TActiveFileUpload
  • TActiveFileUploadCallbackParams
  • TActiveFileUploadItem
  • TActiveHiddenField
  • TActiveHtmlArea
  • TActiveHtmlArea5
  • TActiveHyperLink
  • TActiveHyperLinkColumn
  • TActiveImage
  • TActiveImageButton
  • TActiveLabel
  • TActiveLinkButton
  • TActiveListBox
  • TActiveListControlAdapter
  • TActiveListItemCollection
  • TActiveLiteralColumn
  • TActiveMultiView
  • TActivePageAdapter
  • TActivePager
  • TActivePanel
  • TActiveRadioButton
  • TActiveRadioButtonItem
  • TActiveRadioButtonList
  • TActiveRatingList
  • TActiveRepeater
  • TActiveTableCell
  • TActiveTableCellEventParameter
  • TActiveTableRow
  • TActiveTableRowEventParameter
  • TActiveTemplateColumn
  • TActiveTextBox
  • TBaseActiveCallbackControl
  • TBaseActiveControl
  • TCallback
  • TCallbackClientScript
  • TCallbackClientSide
  • TCallbackErrorHandler
  • TCallbackEventParameter
  • TCallbackOptions
  • TCallbackPageStateTracker
  • TCallbackResponseAdapter
  • TCallbackResponseWriter
  • TEventTriggeredCallback
  • TInPlaceTextBox
  • TInvalidCallbackException
  • TMapCollectionDiff
  • TScalarDiff
  • TStyleDiff
  • TTimeTriggeredCallback
  • TTriggeredCallback
  • TValueTriggeredCallback
  • TViewStateDiff
  • TJuiAutoComplete
  • TJuiAutoCompleteEventParameter
  • TJuiAutoCompleteTemplate
  • TJuiCallbackPageStateTracker
  • TJuiControlAdapter
  • TJuiControlOptions
  • TJuiDatePicker
  • TJuiDialog
  • TJuiDialogButton
  • TJuiDraggable
  • TJuiDroppable
  • TJuiEventParameter
  • TJuiProgressbar
  • TJuiResizable
  • TJuiSelectable
  • TJuiSelectableTemplate
  • TJuiSlider
  • TJuiSortable
  • TJuiSortableTemplate
  • TBroadcastEventParameter
  • TCachePageStatePersister
  • TClientScriptManager
  • TClientSideOptions
  • TCommandEventParameter
  • TCompositeControl
  • TCompositeLiteral
  • TControl
  • TControlAdapter
  • TControlCollection
  • TEmptyControlCollection
  • TEventContent
  • TForm
  • THtmlWriter
  • TPage
  • TPageStateFormatter
  • TPageStatePersister
  • TSessionPageStatePersister
  • TSkinTemplate
  • TTemplate
  • TTemplateControl
  • TTemplateControlInheritable
  • TTemplateManager
  • TTheme
  • TThemeManager
  • TWebColors
  • TAccordion
  • TAccordionView
  • TAccordionViewCollection
  • TBaseDataList
  • TBaseValidator
  • TBoundColumn
  • TBulletedList
  • TBulletedListDisplayMode
  • TBulletedListEventParameter
  • TBulletStyle
  • TButton
  • TButtonColumn
  • TButtonColumnType
  • TButtonTag
  • TButtonType
  • TCaptcha
  • TCaptchaValidator
  • TCheckBox
  • TCheckBoxColumn
  • TCheckBoxItem
  • TCheckBoxList
  • TCircleHotSpot
  • TClientScript
  • TClientSideValidationSummaryOptions
  • TColorPicker
  • TColorPickerClientSide
  • TColorPickerMode
  • TCompareValidator
  • TCompleteWizardStep
  • TConditional
  • TContent
  • TContentDirection
  • TContentPlaceHolder
  • TCustomValidator
  • TDataBoundControl
  • TDataGrid
  • TDataGridColumn
  • TDataGridColumnCollection
  • TDataGridCommandEventParameter
  • TDataGridItem
  • TDataGridItemCollection
  • TDataGridItemEventParameter
  • TDataGridItemRenderer
  • TDataGridPageChangedEventParameter
  • TDataGridPager
  • TDataGridPagerButtonType
  • TDataGridPagerEventParameter
  • TDataGridPagerMode
  • TDataGridPagerPosition
  • TDataGridPagerStyle
  • TDataGridSortCommandEventParameter
  • TDataList
  • TDataListCommandEventParameter
  • TDataListItem
  • TDataListItemCollection
  • TDataListItemEventParameter
  • TDataListItemRenderer
  • TDataRenderer
  • TDataSize
  • TDataSourceControl
  • TDataSourceSelectParameters
  • TDataSourceView
  • TDataTypeValidator
  • TDatePicker
  • TDatePickerClientScript
  • TDatePickerInputMode
  • TDatePickerMode
  • TDatePickerPositionMode
  • TDisplayStyle
  • TDropDownList
  • TDropDownListColumn
  • TEditCommandColumn
  • TEmailAddressValidator
  • TExpression
  • TFileUpload
  • TFileUploadItem
  • TFlushOutput
  • TFont
  • TGravatar
  • THead
  • THeader1
  • THeader2
  • THeader3
  • THeader4
  • THeader5
  • THeader6
  • THiddenField
  • THorizontalAlign
  • THotSpot
  • THotSpotCollection
  • THotSpotMode
  • THtmlArea
  • THtmlArea5
  • THtmlElement
  • THyperLink
  • THyperLinkColumn
  • TImage
  • TImageButton
  • TImageClickEventParameter
  • TImageMap
  • TImageMapEventParameter
  • TInlineFrame
  • TInlineFrameAlign
  • TInlineFrameScrollBars
  • TItemDataRenderer
  • TJavascriptLogger
  • TKeyboard
  • TLabel
  • TLinkButton
  • TListBox
  • TListControl
  • TListControlValidator
  • TListItem
  • TListItemType
  • TListSelectionMode
  • TLiteral
  • TLiteralColumn
  • TMarkdown
  • TMetaTag
  • TMetaTagCollection
  • TMultiView
  • TOutputCache
  • TOutputCacheCalculateKeyEventParameter
  • TOutputCacheCheckDependencyEventParameter
  • TOutputCacheTextWriterMulti
  • TPageLoadTime
  • TPager
  • TPagerButtonType
  • TPagerMode
  • TPagerPageChangedEventParameter
  • TPanel
  • TPanelStyle
  • TPlaceHolder
  • TPolygonHotSpot
  • TRadioButton
  • TRadioButtonItem
  • TRadioButtonList
  • TRangeValidationDataType
  • TRangeValidator
  • TRatingList
  • TReadOnlyDataSource
  • TReadOnlyDataSourceView
  • TReCaptcha
  • TReCaptcha2
  • TReCaptcha2Validator
  • TReCaptchaValidator
  • TRectangleHotSpot
  • TRegularExpressionValidator
  • TRepeatDirection
  • TRepeater
  • TRepeaterCommandEventParameter
  • TRepeaterItem
  • TRepeaterItemCollection
  • TRepeaterItemEventParameter
  • TRepeaterItemRenderer
  • TRepeatInfo
  • TRepeatLayout
  • TRequiredFieldValidator
  • TSafeHtml
  • TScrollBars
  • TServerValidateEventParameter
  • TSlider
  • TSliderClientScript
  • TSliderDirection
  • TStatements
  • TStyle
  • TStyleSheet
  • TTable
  • TTableCaptionAlign
  • TTableCell
  • TTableCellCollection
  • TTableFooterRow
  • TTableGridLines
  • TTableHeaderCell
  • TTableHeaderRow
  • TTableHeaderScope
  • TTableItemStyle
  • TTableRow
  • TTableRowCollection
  • TTableRowSection
  • TTableStyle
  • TTabPanel
  • TTabView
  • TTabViewCollection
  • TTemplateColumn
  • TTemplatedWizardStep
  • TTextAlign
  • TTextBox
  • TTextBoxAutoCompleteType
  • TTextBoxMode
  • TTextHighlighter
  • TTextProcessor
  • TValidationCompareOperator
  • TValidationDataType
  • TValidationSummary
  • TValidationSummaryDisplayMode
  • TValidationSummaryDisplayStyle
  • TValidatorClientSide
  • TValidatorDisplayStyle
  • TVerticalAlign
  • TView
  • TViewCollection
  • TWebControl
  • TWebControlAdapter
  • TWebControlDecorator
  • TWizard
  • TWizardFinishNavigationTemplate
  • TWizardNavigationButtonStyle
  • TWizardNavigationButtonType
  • TWizardNavigationContainer
  • TWizardNavigationEventParameter
  • TWizardNavigationTemplate
  • TWizardSideBarListItemTemplate
  • TWizardSideBarTemplate
  • TWizardStartNavigationTemplate
  • TWizardStep
  • TWizardStepCollection
  • TWizardStepNavigationTemplate
  • TWizardStepType
  • TXmlTransform
  • TXmlDocument
  • TXmlElement
  • TXmlElementList

Interfaces

  • ICache
  • ICacheDependency
  • ICollectionFilter
  • IPriorityCapture
  • IPriorityCollection
  • IPriorityItem
  • IPriorityProperty
  • IWeakCollection
  • IWeakRetainable
  • IScaffoldEditRenderer
  • IMappedStatement
  • IMessageSource
  • IDataRenderer
  • IEventParameter
  • IModule
  • ITextWriter
  • IService
  • ISingleton
  • IStatePersister
  • IUser
  • IUserManager
  • IPermissions
  • IBaseBehavior
  • IBehavior
  • IClassBehavior
  • IDbModule
  • IDynamicMethods
  • IInstanceCheck
  • IOutputLogRoute
  • IPluginModule
  • IFeedContentProvider
  • IActiveControl
  • ICallbackEventHandler
  • IBindable
  • IBroadcastEventReceiver
  • IButtonControl
  • INamingContainer
  • IPageStatePersister
  • IPostBackDataHandler
  • IPostBackEventHandler
  • IRenderable
  • ISurroundable
  • ITemplate
  • ITheme
  • IValidatable
  • IValidator
  • IJuiOptions
  • IDataSource
  • IItemDataRenderer
  • IListControlAdapter
  • IRepeatInfoUser
  • IStyleable

Traits

  • TPriorityCollectionTrait
  • TPriorityPropertyTrait
  • TWeakCollectionTrait
  • TPermissionsManagerPropertyTrait
  • TNoUnserializeBehaviorTrait
  • TNoUnserializeClassBehaviorTrait

Search results

    • Namespaces
    • Errors
    • Deprecated
    • Markers

    Class \Prado\TApplication

    TApplication class.

    TApplication coordinates modules and services, and serves as a configuration context for all Prado components.

    TApplication uses a configuration file to specify the settings of the application, the modules, the services, the parameters, and so on.

    TApplication adopts a modular structure. A TApplication instance is a composition of multiple modules. A module is an instance of class implementing IModule interface. Each module accomplishes certain functionalities that are shared by all Prado components in an application. There are default modules, composer modules, and user-defined modules. The latter offers extreme flexibility of extending TApplication in a plug-and-play fashion. Modules cooperate with each other to serve a user request by following a sequence of lifecycles predefined in TApplication.

    TApplicationConfiguration loads the composer.json for each installed composer extension and checks the extra field for a "bootstrap" class for the package. Packages can be specified as a configuration module (without a class) to load the composer extension module. The ID of the module is the name of the package.

    TApplication has four modes that can be changed by setting \Prado\setMode property (in the application configuration file).

    • Off mode will prevent the application from serving user requests.
    • Debug mode is mainly used during application development. It ensures the cache is always up-to-date if caching is enabled. It also allows exceptions are displayed with rich context information if they occur.
    • Normal mode is mainly used during production stage. Exception information will only be recorded in system error logs. The cache is ensured to be up-to-date if it is enabled.
    • Performance mode is similar to Normal mode except that it does not ensure the cache is up-to-date.

    TApplication dispatches each user request to a particular service which finishes the actual work for the request with the aid from the application modules.

    TApplication maintains a lifecycle with the following stages:

    • [construct] : construction of the application instance
    • [initApplication] : load application configuration and instantiate modules and the requested service
    • onInitComplete : this event happens right after after module and service initialization. This event is particularly useful for CLI/Shell applications
    • onBeginRequest : this event happens right after application initialization
    • onAuthentication : this event happens when authentication is needed for the current request
    • onAuthenticationComplete : this event happens right after the authentication is done for the current request
    • onAuthorization : this event happens when authorization is needed for the current request
    • onAuthorizationComplete : this event happens right after the authorization is done for the current request
    • onLoadState : this event happens when application state needs to be loaded
    • onLoadStateComplete : this event happens right after the application state is loaded
    • onPreRunService : this event happens right before the requested service is to run
    • runService : the requested service runs
    • onSaveState : this event happens when application needs to save its state
    • onSaveStateComplete : this event happens right after the application saves its state
    • onPreFlushOutput : this event happens right before the application flushes output to client side.
    • flushOutput : the application flushes output to client side.
    • onEndRequest : this is the last stage a request is being completed
    • [destruct] : destruction of the application instance Modules and services can attach their methods to one or several of the above events and do appropriate processing when the events are raised. By this way, the application is able to coordinate the activities of modules and services in the above order. To terminate an application before the whole lifecycle completes, call completeRequest.

    Examples:

    • Create and run a Prado application:
    $application=new TApplication($configFile);
    $application->run();
    

    Class hierarchy

    \Prado\TApplication implements ISingleton
    Extended by \Prado\TComponent
    Author: Qiang Xue <qiang.xue@gmail.com>
    Since: 3.0
    Methods summary
    public
    __construct([string $basePath = 'protected' ][, bool $cacheConfig = true ][, string $configType = self::CONFIG_TYPE_XML ]) : mixed
    Constructor.

    Sets application base path and initializes the application singleton. Application base path refers to the root directory storing application data and code not directly accessible by Web users. By default, the base path is assumed to be the protected directory under the directory containing the current running script.

    public
    applyConfiguration(TApplicationConfiguration $config[, bool $withinService = false ]) : mixed
    Applies an application configuration.
    public
    clearGlobalState(string $key) : mixed
    Clears a global value.

    The value cleared will no longer be available in this request and the following requests.

    public
    completeRequest() : mixed
    Completes current request processing.

    This method can be used to exit the application lifecycles after finishing the current cycle.

    public
    flushOutput([bool $continueBuffering = true ]) : mixed
    Flushes output to client side.
    public
    getApplicationStatePersister() : IStatePersister
    public
    getAssetManager() : TAssetManager
    public
    getAuthorizationRules() : TAuthorizationRuleCollection
    public
    getBasePath() : string
    public
    getCache() : null|ICache
    public
    getConfigurationFile() : string
    public
    getConfigurationFileExt() : string
    public
    getConfigurationFileName() : string
    public
    getConfigurationType() : string
    public
    getErrorHandler() : TErrorHandler
    public
    getGlobalization([bool $createIfNotExists = true ]) : null|TGlobalization
    public
    getGlobalState(string $key[, mixed $defaultValue = null ]) : mixed
    Returns a global value.

    A global value is one that is persistent across users sessions and requests.

    public
    getID() : string
    public
    getMode() : string|TApplicationMode
    public
    getModule(mixed $id) : null|TModule
    public
    getModules() : array<string|int, TModule>
    Returns a list of application modules indexed by module IDs.

    Modules that have not been loaded yet are returned as null objects.

    public
    getModulesByType(string $type[, bool $strict = false ]) : array<string|int, mixed>
    Returns a list of application modules of a specific class.

    Lazy Loading Modules are not loaded, and are null but have an ID Key. When null modules are found, load them with getModule. eg.

    foreach (Prado::getApplication()->getModulesByType(\Prado\Caching\ICache::class) as $id => $module) {
    	$module = (!$module) ? $app->getModule($id) : $module;
    	...
    }
    
    public
    getPageServiceID() : string
    public
    getParameters() : TMap
    Returns the list of application parameters.

    Since the parameters are returned as a TMap object, you may use the returned result to access, add or remove individual parameters.

    public
    getRequest() : THttpRequest
    public
    getRequestCompleted() : bool
    public
    getResponse() : THttpResponse
    public
    getRuntimePath() : string
    public
    getSecurityManager() : TSecurityManager
    public
    getService() : TService
    public
    getSession() : THttpSession
    public
    getTemplateManager() : TTemplateManager
    public
    getThemeManager() : TThemeManager
    public
    getUniqueID() : string
    public
    getUser() : IUser
    public
    onAuthentication() : mixed
    Raises OnAuthentication event.

    This method is invoked when the user request needs to be authenticated.

    public
    onAuthenticationComplete() : mixed
    Raises OnAuthenticationComplete event.

    This method is invoked right after the user request is authenticated.

    public
    onAuthorization() : mixed
    Raises OnAuthorization event.

    This method is invoked when the user request needs to be authorized.

    public
    onAuthorizationComplete() : mixed
    Raises OnAuthorizationComplete event.

    This method is invoked right after the user request is authorized.

    public
    onBeginRequest() : mixed
    Raises OnBeginRequest event.

    At the time when this method is invoked, application modules are loaded and initialized, user request is resolved and the corresponding service is loaded and initialized. The application is about to start processing the user request.

    public
    onEndRequest() : mixed
    Raises OnEndRequest event.

    This method is invoked when the application completes the processing of the request.

    public
    onError(mixed $param) : mixed
    Raises OnError event.

    This method is invoked when an exception is raised during the lifecycles of the application.

    public
    onInitComplete() : mixed
    Raises onInitComplete event.

    At the time when this method is invoked, application modules are loaded, user request is resolved and the corresponding service is loaded and initialized. The application is about to start processing the user request. This call is important for CLI/Shell applications that do not have a web service lifecycle stack. This is the first and last event for finalization of any loaded modules in CLI/Shell mode.

    public
    onLoadState() : mixed
    Raises OnLoadState event.

    This method is invoked when the application needs to load state (probably stored in session).

    public
    onLoadStateComplete() : mixed
    Raises OnLoadStateComplete event.

    This method is invoked right after the application state has been loaded.

    public
    onPreFlushOutput() : mixed
    Raises OnPreFlushOutput event.

    This method is invoked right before the application flushes output to client.

    public
    onPreRunService() : mixed
    Raises OnPreRunService event.

    This method is invoked right before the service is to be run.

    public
    onSaveState() : mixed
    Raises OnSaveState event.

    This method is invoked when the application needs to save state (probably stored in session).

    public
    onSaveStateComplete() : mixed
    Raises OnSaveStateComplete event.

    This method is invoked right after the application state has been saved.

    public
    onSetUser(IUser $user) : mixed
    Raises onSetUser event.

    Allows modules/components to run handlers when the Application User is set. e.g. A user module could set the $_SERVER['HTTP_ACCEPT_LANGUAGE'] and $_SERVER['HTTP_ACCEPT_CHARSET'] in a cli environment to the user's last web Language and Charset so Emails (and other templates) get language customized.

    public
    run() : mixed
    Executes the lifecycles of the application.

    This is the main entry function that leads to the running of the whole Prado application.

    public
    runService() : mixed
    Runs the requested service.
    public
    setApplicationStatePersister(IStatePersister $persister) : mixed
    public
    setAssetManager(TAssetManager $value) : mixed
    public
    setBasePath(string $value) : mixed
    public
    setCache(ICache $cache) : mixed
    public
    setConfigurationFile(string $value) : mixed
    public
    setConfigurationType(string $value) : mixed
    public
    setErrorHandler(TErrorHandler $handler) : mixed
    public
    setGlobalization(TGlobalization $glob) : mixed
    public
    setGlobalState(string $key, mixed $value[, null|mixed $defaultValue = null ][, bool $forceSave = false ]) : mixed
    Sets a global value.

    A global value is one that is persistent across users sessions and requests. Make sure that the value is serializable and unserializable.

    public
    setID(string $value) : mixed
    public
    setMode(TApplicationMode $value) : mixed
    public
    setModule(string $id[, null|IModule $module = null ]) : mixed
    Adds a module to application.

    Note, this method does not do module initialization.

    public
    setPageServiceID(string $value) : mixed
    public
    setRequest(THttpRequest $request) : mixed
    public
    setResponse(THttpResponse $response) : mixed
    public
    setRuntimePath(string $value) : mixed
    public
    setSecurityManager(TSecurityManager $sm) : mixed
    public
    setService(IService $value) : mixed
    public
    setSession(THttpSession $session) : mixed
    public
    setTemplateManager(TTemplateManager $value) : mixed
    public
    setThemeManager(TThemeManager $value) : mixed
    public
    setUser(IUser $user) : mixed
    This sets the application user and raises the onSetUser event.
    public static
    singleton([bool $create = true ]) : object|null
    Returns the current Prado application. This enables application behaviors to be used for undefined static function calls via {@see \Prado\TComponent::__callStatic}.
    public
    startService(string $serviceID) : mixed
    Starts the specified service.

    The service instance will be created. Its properties will be initialized and the configurations will be applied, if any.

    protected
    getApplicationConfigurationClass() : mixed
    protected
    initApplication() : mixed
    Loads configuration and initializes application.

    Configuration file will be read and parsed (if a valid cached version exists, it will be used instead). Then, modules are created and initialized; Afterwards, the requested service is created and initialized. Lastly, the onInitComplete event is raised.

    protected
    internalLoadModule(mixed $id[, mixed $force = false ]) : mixed
    protected
    loadGlobals() : mixed
    Loads global values from persistent storage.

    This method is invoked when \Prado\onLoadState event is raised. After this method, values that are stored in previous requests become available to the current request via getGlobalState.

    protected
    resolvePaths(string $basePath) : mixed
    Resolves application-relevant paths.

    This method is invoked by the application constructor to determine the application configuration file, application root path and the runtime path.

    protected
    saveGlobals() : mixed
    Saves global values into persistent storage.

    This method is invoked when \Prado\onSaveState event is raised.

    Inherited methods
    __call, __callStatic, __clone, __construct, __destruct, __get, __isset, __set, __sleep, __unset, __wakeup, addParsedObject, asa, attachBehavior, attachBehaviors, attachClassBehavior, attachEventHandler, callBehaviorsMethod, canGetProperty, canSetProperty, clearBehaviors, createdOnTemplate, detachBehavior, detachBehaviors, detachClassBehavior, detachEventHandler, disableBehavior, disableBehaviors, enableBehavior, enableBehaviors, evaluateExpression, evaluateStatements, fxAttachClassBehavior, fxDetachClassBehavior, getAutoGlobalListen, getBehaviors, getBehaviorsEnabled, getClassHierarchy, getEventHandlers, getListeningToGlobalEvents, getSubProperty, hasEvent, hasEventHandler, hasMethod, hasProperty, isa, listen, raiseEvent, setSubProperty, unlisten, _getZappableSleepProps, getCallChain, getClassFxEvents, instanceBehavior, filter_prado_fx
    Constants summary
    public mixed CONFIG_FILE_EXT_PHP
    File extension for external config files
    '.php'
    public mixed CONFIG_FILE_EXT_XML
    File extension for external config files
    '.xml'
    public mixed CONFIG_FILE_PHP
    Application configuration file name
    'application.php'
    public mixed CONFIG_FILE_XML
    Application configuration file name
    'application.xml'
    public mixed CONFIG_TYPE_PHP
    Configuration file type, application.php and config.php
    'php'
    public mixed CONFIG_TYPE_XML
    Configuration file type, application.xml and config.xml
    'xml'
    public mixed CONFIGCACHE_FILE
    Config cache file
    'config.cache'
    public mixed GLOBAL_FILE
    Global data file
    'global.cache'
    public mixed PAGE_SERVICE_ID
    Page service ID
    'page'
    public mixed RUNTIME_PATH
    Runtime directory name
    'runtime'
    Inherited constants
    \Prado\TComponent::GLOBAL_RAISE_EVENT_LISTENER
    Prado 4.3.0 API Manual