Created
January 30, 2015 11:17
-
-
Save sagikazarmark/490f37c98eb59b09015b to your computer and use it in GitHub Desktop.
Generic service provider
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class SomeServiceProvider | |
{ | |
public $provides = array( | |
'service', | |
'service.one', | |
'service.two', | |
); | |
public function provide() | |
{ | |
$this->container->add('service', 'Service'); | |
$this->container->add('service.one', 'Service1'); | |
$this->container->add('service.two', 'Service2'); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I'd make provides a method.