1. Go to this page and download the library: Download ray/fake-module library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
ray / fake-module example snippets
use Ray\Di\AbstractModule;
use Ray\FakeModule\FakeModule;
class AppModule extends AbstractModule
{
protected function configure()
{
$this->install(new FakeModule);
}
}
namespace FakeVendor\Sandbox\Resource\App;
use BEAR\Resource\ResourceObject;
use Ray\FakeModule\Annotation\FakeResource;
/**
* @FakeResource
*/
class User extends ResourceObject
{
public function onGet($id)
{
// ...
}
}
namespace FakeVendor\Sandbox\Resource\App;
use BEAR\Resource\ResourceObject;
class FakeUser extends ResourceObject
{
public function onGet($id)
{
// ...
}
}
namespace FakeVendor\Sandbox\Module;
use Ray\FakeModule\Annotation\FakeClass;
/**
* @FakeClass
*/
class TestClass
{
public function output() {
return "test class output";
}
}
namespace FakeVendor\Sandbox\Module;
class FakeTestClass
{
public function output() {
return "fake class output";
}
}
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.