@@ -141,7 +141,7 @@ discard block |
||
141 | 141 | * |
142 | 142 | * @implements \PEIP\INF\Context\Context |
143 | 143 | * @access public |
144 | - * @param \PEIP\INF\Context\Context_Plugin $plugin a plugin instance |
|
144 | + * @param \PEIP\INF\Context\ContextPlugin $plugin a plugin instance |
|
145 | 145 | */ |
146 | 146 | public function addPlugin(\PEIP\INF\Context\ContextPlugin $plugin){ |
147 | 147 | $plugin->init($this); |
@@ -173,7 +173,6 @@ discard block |
||
173 | 173 | * </config> |
174 | 174 | * |
175 | 175 | * @access public |
176 | - * @param XMLContext $config the config to include |
|
177 | 176 | */ |
178 | 177 | public function includeContext(XMLContext $context){ |
179 | 178 | $this->services = array_merge($this->services, $context->getServices()); |
@@ -184,7 +183,7 @@ discard block |
||
184 | 183 | * |
185 | 184 | * @see XMLContext::includeContext |
186 | 185 | * @access public |
187 | - * @param XMLContext $context the config to include |
|
186 | + * @param string $filePath |
|
188 | 187 | */ |
189 | 188 | public function includeContextFromFile($filePath){ |
190 | 189 | if(file_exists($filePath)){ |
@@ -363,7 +362,7 @@ discard block |
||
363 | 362 | * |
364 | 363 | * @access public |
365 | 364 | * @param $config |
366 | - * @return object the initialized service instance |
|
365 | + * @return \PEIP\INF\Context\ContextPlugin the initialized service instance |
|
367 | 366 | */ |
368 | 367 | public function createService(array $config){ |
369 | 368 | return ServiceFactory::createService($config); |
@@ -638,7 +637,7 @@ discard block |
||
638 | 637 | * |
639 | 638 | * @access protected |
640 | 639 | * @param object $config configuration object to create arguments from. |
641 | - * @return mixed build arguments |
|
640 | + * @return \PEIP\INF\Channel\Channel[] build arguments |
|
642 | 641 | */ |
643 | 642 | protected function getReplyHandlerArguments($config){ |
644 | 643 | $args = array( |
@@ -683,7 +682,8 @@ discard block |
||
683 | 682 | * |
684 | 683 | * @access protected |
685 | 684 | * @param string the configuration type ofthe channel (e.g.: 'reply', 'request') |
686 | - * @param object $config configuration object to return channel from. |
|
685 | + * @param object $config configuration object to return channel from. |
|
686 | + * @param string $type |
|
687 | 687 | * @return \PEIP\INF\Channel\Channel reply-channel |
688 | 688 | */ |
689 | 689 | public function doGetChannel($type, $config){ |
@@ -737,7 +737,7 @@ discard block |
||
737 | 737 | * @see GenericBuilder |
738 | 738 | * @static |
739 | 739 | * @access protected |
740 | - * @param object $className name of class to build instance for. |
|
740 | + * @param string $className name of class to build instance for. |
|
741 | 741 | * @param array $arguments arguments for the constructor |
742 | 742 | * @return object build and modified srvice instance |
743 | 743 | */ |
@@ -133,7 +133,7 @@ |
||
133 | 133 | * @param callable $callable a callable which creates instances for node-name |
134 | 134 | */ |
135 | 135 | public function registerNodeBuilder($nodeName, $callable){ |
136 | - return $this->getServiceProvider()->registerNodeBuilder($nodeName, $callable); |
|
136 | + return $this->getServiceProvider()->registerNodeBuilder($nodeName, $callable); |
|
137 | 137 | } |
138 | 138 | |
139 | 139 | /** |
@@ -16,13 +16,13 @@ discard block |
||
16 | 16 | use PEIP\Context\XMLContext; |
17 | 17 | |
18 | 18 | class ServiceFactory { |
19 | - /** |
|
20 | - * Creates and initializes service instance from a given configuration. |
|
21 | - * |
|
22 | - * @access public |
|
23 | - * @param $config configuration of the service |
|
24 | - * @return object the initialized service instance |
|
25 | - */ |
|
19 | + /** |
|
20 | + * Creates and initializes service instance from a given configuration. |
|
21 | + * |
|
22 | + * @access public |
|
23 | + * @param $config configuration of the service |
|
24 | + * @return object the initialized service instance |
|
25 | + */ |
|
26 | 26 | public static function createService(array $config){ |
27 | 27 | $args = array(); |
28 | 28 | //build arguments for constructor |
@@ -35,15 +35,15 @@ discard block |
||
35 | 35 | } |
36 | 36 | |
37 | 37 | /** |
38 | - * Builds an arbitrary service/object instance from a config-obect. |
|
39 | - * |
|
40 | - * @static |
|
41 | - * @access protected |
|
42 | - * @param object $config configuration object to build a service instance from. |
|
43 | - * @param array $arguments arguments for the service constructor |
|
44 | - * @param string $defaultClass class to create instance for if none is set in config |
|
45 | - * @return object build and modified srvice instance |
|
46 | - */ |
|
38 | + * Builds an arbitrary service/object instance from a config-obect. |
|
39 | + * |
|
40 | + * @static |
|
41 | + * @access protected |
|
42 | + * @param object $config configuration object to build a service instance from. |
|
43 | + * @param array $arguments arguments for the service constructor |
|
44 | + * @param string $defaultClass class to create instance for if none is set in config |
|
45 | + * @return object build and modified srvice instance |
|
46 | + */ |
|
47 | 47 | public static function doBuild($config, $arguments, $defaultClass = false){ |
48 | 48 | $cls = isset($config["class"]) ? trim((string)$config["class"]) : (string)$defaultClass; |
49 | 49 | if($cls != ''){ |
@@ -80,12 +80,12 @@ discard block |
||
80 | 80 | } |
81 | 81 | |
82 | 82 | /** |
83 | - * Builds single argument (to call a method with later) from a config-obect. |
|
84 | - * |
|
85 | - * @access protected |
|
86 | - * @param object $config configuration object to create argument from. |
|
87 | - * @return mixed build argument |
|
88 | - */ |
|
83 | + * Builds single argument (to call a method with later) from a config-obect. |
|
84 | + * |
|
85 | + * @access protected |
|
86 | + * @param object $config configuration object to create argument from. |
|
87 | + * @return mixed build argument |
|
88 | + */ |
|
89 | 89 | protected function buildArg($config){ |
90 | 90 | if(trim((string)$config['value']) != ''){ |
91 | 91 | $arg = (string)$config['value']; |
@@ -128,7 +128,7 @@ discard block |
||
128 | 128 | */ |
129 | 129 | public static function buildAndModify(array $config, $arguments, $defaultClass = ""){ |
130 | 130 | if((isset($config["class"]) && "" != (string)$config["class"]) || $defaultClass !== ""){ |
131 | - $service = ServiceFactory::doBuild($config, $arguments, $defaultClass); |
|
131 | + $service = ServiceFactory::doBuild($config, $arguments, $defaultClass); |
|
132 | 132 | }else{ |
133 | 133 | throw new \RuntimeException('Could not create Service. no class or reference given.'); |
134 | 134 | } |
@@ -49,10 +49,10 @@ |
||
49 | 49 | } |
50 | 50 | |
51 | 51 | /** |
52 | - * @access public |
|
53 | - * @param $observer |
|
54 | - * @return |
|
55 | - */ |
|
52 | + * @access public |
|
53 | + * @param $observer |
|
54 | + * @return |
|
55 | + */ |
|
56 | 56 | public function addObserver(\PEIP\INF\Event\Observer $observer){ |
57 | 57 | $this->observers[] = $observer; |
58 | 58 | } |