MailPoet\EmailEditor
Container::set()
The method for registering a new service
Method of the class: Container{}
No Hooks.
Return
null
. Nothing (null).
Usage
$Container = new Container(); $Container->set( $name, $callback ): void;
- $name(string) (required)
- The name of the service.
- $callback(callable) (required)
- The callable that will be used to create the service.
Container::set() Container::set code WC 9.8.2
public function set( string $name, callable $callback ): void { $this->services[ $name ] = $callback; }