Namespaces

  • Latte
    • Loaders
    • Macros
    • Runtime
  • Nette
    • Application
      • Responses
      • Routers
      • UI
    • Bridges
      • ApplicationDI
      • ApplicationLatte
      • ApplicationTracy
      • CacheDI
      • CacheLatte
      • DatabaseDI
      • DatabaseTracy
      • DITracy
      • FormsDI
      • FormsLatte
      • Framework
      • HttpDI
      • HttpTracy
      • MailDI
      • ReflectionDI
      • SecurityDI
      • SecurityTracy
    • Caching
      • Storages
    • ComponentModel
    • Database
      • Conventions
      • Drivers
      • Reflection
      • Table
    • DI
      • Config
        • Adapters
      • Extensions
    • Forms
      • Controls
      • Rendering
    • Http
    • Iterators
    • Loaders
    • Localization
    • Mail
    • Neon
    • PhpGenerator
    • Reflection
    • Security
    • Utils
  • none
  • Tracy
    • Bridges
      • Nette

Classes

  • Component
  • Container

Interfaces

  • IComponent
  • IContainer
  • Overview
  • Namespace
  • Class
  • Tree
  • Deprecated
  • Other releases
  • Nette homepage

Class Container

ComponentContainer is default implementation of IContainer.

Nette\Object
Extended by Nette\ComponentModel\Component implements Nette\ComponentModel\IComponent
Extended by Nette\ComponentModel\Container implements Nette\ComponentModel\IContainer

Direct known subclasses

Nette\Application\UI\PresenterComponent, Nette\Forms\Container

Indirect known subclasses

Nette\Application\UI\Control, Nette\Application\UI\Form, Nette\Application\UI\Multiplier, Nette\Application\UI\Presenter, Nette\Forms\Form
Namespace: Nette\ComponentModel
Located at ComponentModel/Container.php
Methods summary
public Nette\ComponentModel\Container
# addComponent( Nette\ComponentModel\IComponent $component, string $name, string $insertBefore = NULL )

Adds the specified component to the IContainer.

Adds the specified component to the IContainer.

Parameters

$component
$name
$insertBefore

Returns

Nette\ComponentModel\Container
static

Throws

Nette\InvalidStateException
Nette\InvalidStateException

Implementation of

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

Removes a component from the IContainer.

Removes a component from the IContainer.

Parameters

$component

Implementation of

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

Returns component specified by name or path.

Returns component specified by name or path.

Parameters

$name
$need
exception if component doesn't exist?

Returns

Nette\ComponentModel\IComponent|null
IComponent|NULL

Implementation of

Nette\ComponentModel\IContainer::getComponent()
protected Nette\ComponentModel\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
name

Returns

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

Iterates over components.

Iterates over components.

Parameters

$deep
recursive?
$filterType
types filter

Returns

ArrayIterator
\ArrayIterator

Implementation of

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

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

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

Throws

Nette\InvalidStateException
Nette\InvalidStateException
public
# __clone( )

Object cloning.

Object cloning.

Overrides

Nette\ComponentModel\Component::__clone()
Methods inherited from Nette\ComponentModel\Component
__construct(), __sleep(), __wakeup(), attached(), detached(), getName(), getParent(), lookup(), lookupPath(), monitor(), unmonitor(), validateParent()
Methods inherited from Nette\Object
__call(), __callStatic(), __get(), __isset(), __set(), __unset(), extensionMethod(), getReflection()
Methods inherited from Nette\ComponentModel\IComponent
setParent()
Constants inherited from Nette\ComponentModel\IComponent
NAME_SEPARATOR
Magic properties summary
public read-only ArrayIterator $components
Magic properties inherited from Nette\ComponentModel\Component
$name, $parent
Magic properties inherited from Nette\Object
$reflection
Nette 2.3-20161221 API API documentation generated by ApiGen 2.8.0