Namespaces

  • Nette
    • Application
    • Caching
    • Collections
    • Config
    • Forms
    • IO
    • Loaders
    • Mail
    • Reflection
    • Security
    • Templates
    • Web
  • None
  • PHP

Classes

  • ArrayTools
  • Callback
  • Component
  • ComponentContainer
  • Configurator
  • DateTime
  • Debug
  • Environment
  • Framework
  • FreezableObject
  • GenericRecursiveIterator
  • Image
  • ImageMagick
  • InstanceFilterIterator
  • Object
  • ObjectMixin
  • Paginator
  • RecursiveComponentIterator
  • ServiceLocator
  • SmartCachingIterator
  • String
  • Tools

Interfaces

  • IComponent
  • IComponentContainer
  • IDebuggable
  • IServiceLocator
  • ITranslator

Exceptions

  • AmbiguousServiceException
  • Overview
  • Namespace
  • Class
  • Tree
  • Other releases

Class ComponentContainer

ComponentContainer is default implementation of IComponentContainer.

Nette\Object
Extended by Nette\Component implements Nette\IComponent
Extended by Nette\ComponentContainer implements Nette\IComponentContainer

Direct known subclasses

Nette\Application\PresenterComponent, Nette\Forms\FormContainer

Indirect known subclasses

Nette\Application\AppForm, Nette\Application\Control, Nette\Application\Presenter, Nette\Forms\Form
Namespace: Nette
Author: David Grudl
Located at ComponentModel/ComponentContainer.php
Methods summary
public
# addComponent( Nette\IComponent $component, string $name, string $insertBefore = NULL )

Adds the specified component to the IComponentContainer.

Adds the specified component to the IComponentContainer.

Parameters

$component
Nette\IComponent
$name
string
$insertBefore
string

Throws

InvalidStateException

Implementation of

Nette\IComponentContainer::addComponent
public
# removeComponent( Nette\IComponent $component )

Removes a component from the IComponentContainer.

Removes a component from the IComponentContainer.

Parameters

$component
Nette\IComponent

Implementation of

Nette\IComponentContainer::removeComponent
final public Nette\IComponent|null
# getComponent( string $name, boolean $need = TRUE )

Returns component specified by name or path.

Returns component specified by name or path.

Parameters

$name
string
$need
boolean
throw exception if component doesn't exist?

Returns

Nette\IComponent|null

Implementation of

Nette\IComponentContainer::getComponent
protected Nette\IComponent
# createComponent( string $name )

Component factory. Delegates the creation of components to a createComponent<Name> method.

Component factory. Delegates the creation of components to a createComponent<Name> method.

Parameters

$name
string
component name

Returns

Nette\IComponent
the created component (optionally)
final public ArrayIterator
# getComponents( boolean $deep = FALSE, string $filterType = NULL )

Iterates over a components.

Iterates over a components.

Parameters

$deep
boolean
recursive?
$filterType
string
class types filter

Returns

ArrayIterator

Implementation of

Nette\IComponentContainer::getComponents
protected
# validateChildComponent( Nette\IComponent $child )

Descendant can override this method to disallow insert a child by throwing an \InvalidStateException.

Descendant can override this method to disallow insert a child by throwing an \InvalidStateException.

Parameters

$child
Nette\IComponent

Throws

InvalidStateException
public
# __clone( )

Object cloning.

Object cloning.

Methods inherited from Nette\Component
__construct(), __wakeup(), attached(), detached(), getName(), getParent(), lookup(), lookupPath(), monitor(), setParent(), unmonitor(), validateParent()
Methods inherited from Nette\Object
__call(), __callStatic(), __get(), __isset(), __set(), __unset(), extensionMethod(), getReflection()
Constants inherited from Nette\IComponent
NAME_SEPARATOR
Nette Framework 0.9.7 API documentation generated by ApiGen 2.3.0