added facades for core classes.
This commit is contained in:
15
laravel/facade.php
Normal file
15
laravel/facade.php
Normal file
@@ -0,0 +1,15 @@
|
||||
<?php namespace Laravel;
|
||||
|
||||
abstract class Facade {
|
||||
|
||||
/**
|
||||
* Magic Method for passing methods to a class registered in the IoC container.
|
||||
* This provides a convenient method of accessing functions on classes that
|
||||
* could not otherwise be accessed staticly.
|
||||
*/
|
||||
public static function __callStatic($method, $parameters)
|
||||
{
|
||||
return call_user_func_array(array(IoC::container()->resolve('laravel.'.static::$resolve), $method), $parameters);
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user