opensoft / epl
The library is a php wrapper for the EPL2 Programming Language. At present do not support all commands EPL2.
Installs: 17 503
Dependents: 1
Suggesters: 0
Security: 0
Stars: 10
Watchers: 5
Forks: 6
Open Issues: 1
Requires
- php: >=5.3.3
This package is not auto-updated.
Last update: 2024-12-21 14:53:13 UTC
README
The library is a php wrapper for the EPL2 Programming Language. At present do not support all commands EPL2.
Usage:
<?php use Epl\CommandComposite; use Epl\CommandHelper; $composite = new Composite(); $commandHelper = new CommandHelper($composite); //Draw new line $commandHelper->lineDrawBlack(50, 200, 400, 20); //Draw other line $commandHelper->lineDrawBlack(200, 50, 20, 400); //Print 1 label $commandHelper->print(1); //Get EPL string $eplString = $commandHelper->toEplString();
To implement the commands necessary to implement Epl\CommandInterface.
For convenience of use EPL commands there is a CommandHelper. It hides the implementation EPL commands. But you can direct way to instantiate the command.
<?php use Epl\Command\PrintCommand; use Epl\Command\CommandComposite; $commandComposite = new CommandComposite(); $printCommand = new PrintCommand(1); $commandComposite->addCommand($printCommand); $eplString = $commandComposite->toEplString();
Installation
php composer.phar require opensoft/epl
Installation on Symfony 2 project
If you use a deps file, add:[epl] git=http://github.com/opensoft/epl.git
Or if you want to clone the repos:
git clone git://github.com/opensoft/epl.git vendor/epl
Add the namespace to your autoloader
$loader->registerNamespaces(array( ............ 'Epl' => DIR.'/../vendor/epl/src', ........... ));