PHP code example of clarkeash / factory

1. Go to this page and download the library: Download clarkeash/factory 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/ */

    

clarkeash / factory example snippets




namespace Acme;

class Application
{

}



namespace Acme;

abstract class Example
{

}



namespace Acme;

interface ExampleInterface
{

}



namespace Acme;

trait ExampleTrait
{

}



use Acme\Application;

class ApplicationTest extends \PHPUnit_Framework_TestCase
{
    /**
     * @var Application
     */
    protected $unit;

    public function setUp()
    {
        $this->unit = new Application();
    }

    /**
     * @test
     */
    public function it_works()
    {
        $this->assertTrue(true);
    }
}