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: 2022-11-05 14:40:30 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();