PHP 트레잇 Nextras\Forms\Controls\Fragments\ComponentControlTrait

저자: Jan Skrasek
파일 보기 프로젝트 열기: nextras/forms

공개 프로퍼티들

프로퍼티 타입 설명
$onAnchor function (self $sender); Occurs when component is attached to presenter

보호된 프로퍼티들

프로퍼티 타입 설명
$params array

공개 메소드들

메소드 설명
__clone ( ) Object cloning.
_isCloning ( ) : null | Nette\ComponentModel\IComponent Is container cloning now?
addComponent ( Nette\ComponentModel\IComponent $component, $name, $insertBefore = NULL ) : self Adds the specified component to the IContainer.
checkRequirements ( $element ) : void Checks for requirements such as authorization.
formatSignalMethod ( $signal ) : string Formats signal handler method name -> case sensitivity doesn't matter.
getComponent ( $name, $need = TRUE ) : Nette\ComponentModel\IComponent | null Returns component specified by name or path.
getComponents ( $deep = FALSE, $filterType = NULL ) : ArrayIterator Iterates over components.
getParam ( $name = NULL, $default = NULL )
getParameter ( $name, $default = NULL ) : mixed Returns component param.
getParameterId ( $name ) : string Returns a fully-qualified name that uniquely identifies the parameter.
getParameters ( ) : array Returns component parameters.
getPersistentParams ( ) : array Returns array of classes persistent parameters. They have public visibility and are non-static.
getPresenter ( $need = TRUE ) : Nette\Application\UI\Presenter | null Returns the presenter where this component belongs to.
getReflection ( ) : Nette\Application\UI\ComponentReflection Access to reflection.
getUniqueId ( ) : string Returns a fully-qualified name that uniquely identifies the component within the presenter hierarchy.
link ( $destination, $args = [] ) : string Generates URL to presenter, action or signal.
loadState ( array $params ) : void Loads state informations.
offsetExists ( $name ) : boolean Does component specified by name exists?
offsetGet ( $name ) : Nette\ComponentModel\IComponent Returns component specified by name. Throws exception if component doesn't exist.
offsetSet ( $name, $component ) : void Adds the component to the container.
offsetUnset ( $name ) : void Removes component from the container.
removeComponent ( Nette\ComponentModel\IComponent $component ) : void Removes a component from the IContainer.
saveState ( array &$params, $reflection = NULL ) : void Saves state informations for next request.
signalReceived ( $signal ) : void Calls signal handler method.

보호된 메소드들

메소드 설명
attached ( $presenter ) : void This method will be called when the component (or component's parent) becomes attached to a monitored object. Do not call this method yourself.
createComponent ( $name ) : Nette\ComponentModel\IComponent Component factory. Delegates the creation of components to a createComponent method.
tryCall ( $method, array $params ) : boolean Calls public method if exists.
validateChildComponent ( Nette\ComponentModel\IComponent $child ) : void Descendant can override this method to disallow insert a child by throwing an Nette\InvalidStateException.
validateParent ( Nette\ComponentModel\IContainer $parent ) : void

메소드 상세

__clone() 공개 메소드

Object cloning.
public __clone ( )

_isCloning() 공개 메소드

Is container cloning now?
public _isCloning ( ) : null | Nette\ComponentModel\IComponent
리턴 null | Nette\ComponentModel\IComponent

addComponent() 공개 메소드

Adds the specified component to the IContainer.
public addComponent ( Nette\ComponentModel\IComponent $component, $name, $insertBefore = NULL ) : self
$component Nette\ComponentModel\IComponent
리턴 self

attached() 보호된 메소드

This method will be called when the component (or component's parent) becomes attached to a monitored object. Do not call this method yourself.
protected attached ( $presenter ) : void
리턴 void

checkRequirements() 공개 메소드

Checks for requirements such as authorization.
public checkRequirements ( $element ) : void
리턴 void

createComponent() 보호된 메소드

Component factory. Delegates the creation of components to a createComponent method.
protected createComponent ( $name ) : Nette\ComponentModel\IComponent
리턴 Nette\ComponentModel\IComponent the created component (optionally)

formatSignalMethod() 공개 정적인 메소드

Formats signal handler method name -> case sensitivity doesn't matter.
public static formatSignalMethod ( $signal ) : string
리턴 string

getComponent() 공개 메소드

Returns component specified by name or path.
public getComponent ( $name, $need = TRUE ) : Nette\ComponentModel\IComponent | null
리턴 Nette\ComponentModel\IComponent | null

getComponents() 공개 메소드

Iterates over components.
public getComponents ( $deep = FALSE, $filterType = NULL ) : ArrayIterator
리턴 ArrayIterator

getParam() 공개 메소드

사용 중단:
public getParam ( $name = NULL, $default = NULL )

getParameter() 공개 메소드

Returns component param.
public getParameter ( $name, $default = NULL ) : mixed
리턴 mixed

getParameterId() 공개 메소드

Returns a fully-qualified name that uniquely identifies the parameter.
public getParameterId ( $name ) : string
리턴 string

getParameters() 공개 메소드

Returns component parameters.
public getParameters ( ) : array
리턴 array

getPersistentParams() 공개 정적인 메소드

This default implementation detects persistent parameters by annotation @persistent.
public static getPersistentParams ( ) : array
리턴 array

getPresenter() 공개 메소드

Returns the presenter where this component belongs to.
public getPresenter ( $need = TRUE ) : Nette\Application\UI\Presenter | null
리턴 Nette\Application\UI\Presenter | null

getReflection() 공개 정적인 메소드

Access to reflection.
public static getReflection ( ) : Nette\Application\UI\ComponentReflection
리턴 Nette\Application\UI\ComponentReflection

getUniqueId() 공개 메소드

Returns a fully-qualified name that uniquely identifies the component within the presenter hierarchy.
public getUniqueId ( ) : string
리턴 string

loadState() 공개 메소드

Loads state informations.
public loadState ( array $params ) : void
$params array
리턴 void

offsetExists() 공개 메소드

Does component specified by name exists?
public offsetExists ( $name ) : boolean
리턴 boolean

offsetGet() 공개 메소드

Returns component specified by name. Throws exception if component doesn't exist.
public offsetGet ( $name ) : Nette\ComponentModel\IComponent
리턴 Nette\ComponentModel\IComponent

offsetSet() 공개 메소드

Adds the component to the container.
public offsetSet ( $name, $component ) : void
리턴 void

offsetUnset() 공개 메소드

Removes component from the container.
public offsetUnset ( $name ) : void
리턴 void

removeComponent() 공개 메소드

Removes a component from the IContainer.
public removeComponent ( Nette\ComponentModel\IComponent $component ) : void
$component Nette\ComponentModel\IComponent
리턴 void

saveState() 공개 메소드

Saves state informations for next request.
public saveState ( array &$params, $reflection = NULL ) : void
$params array
리턴 void

signalReceived() 공개 메소드

Calls signal handler method.
public signalReceived ( $signal ) : void
리턴 void

tryCall() 보호된 메소드

Calls public method if exists.
protected tryCall ( $method, array $params ) : boolean
$params array
리턴 boolean does method exist?

validateChildComponent() 보호된 메소드

Descendant can override this method to disallow insert a child by throwing an Nette\InvalidStateException.
protected validateChildComponent ( Nette\ComponentModel\IComponent $child ) : void
$child Nette\ComponentModel\IComponent
리턴 void

validateParent() 보호된 메소드

protected validateParent ( Nette\ComponentModel\IContainer $parent ) : void
$parent Nette\ComponentModel\IContainer
리턴 void

프로퍼티 상세

$onAnchor 공개적으로 프로퍼티

function (self $sender); Occurs when component is attached to presenter
public $onAnchor

$params 보호되어 있는 프로퍼티

protected array $params
리턴 array