pe/component-class-compiler

Component allows to compile multiple classes into one big string which can be dumped to file

v1.0.0 2017-12-06 11:07 UTC

This package is auto-updated.

Last update: 2024-11-05 19:32:52 UTC


README

Installation

php composer.phar require cmf/component-class-compiler:1.0.0

Usage

use CMF\Component\ClassCompiler\ClassCache;
use CMF\Component\ClassCompiler\ClassCompiler;

// Instantiate class compiler
$classCompiler = new ClassCompiler();

// Add classes to compile (include dependencies)
$classCompiler->addClasses([
    'Foo',
    'Bar',
]);

// Compiles classes to string which can be saved as php file
$classCompiler->compile();