1: <?php
2:
3: /**
4: * This file is part of the Nette Framework.
5: *
6: * Copyright (c) 2004, 2010 David Grudl (http://davidgrudl.com)
7: *
8: * This source file is subject to the "Nette license", and/or
9: * GPL license. For more information please see http://nette.org
10: * @package Nette
11: */
12:
13:
14:
15: /**
16: * Containers are objects that logically contain zero or more IComponent components.
17: *
18: * @author David Grudl
19: */
20: interface IComponentContainer extends IComponent
21: {
22:
23: /**
24: * Adds the specified component to the IComponentContainer.
25: * @param IComponent
26: * @param string
27: * @return void
28: */
29: function addComponent(IComponent $component, $name);
30:
31: /**
32: * Removes a component from the IComponentContainer.
33: * @param IComponent
34: * @return void
35: */
36: function removeComponent(IComponent $component);
37:
38: /**
39: * Returns single component.
40: * @param string
41: * @return IComponent|NULL
42: */
43: function getComponent($name);
44:
45: /**
46: * Iterates over a components.
47: * @param bool recursive?
48: * @param string class types filter
49: * @return Iterator
50: */
51: function getComponents($deep = FALSE, $filterType = NULL);
52:
53: }
54: