Download the PHP package wyrihaximus/tactician-job-command-mapper without Composer
On this page you can find all versions of the php package wyrihaximus/tactician-job-command-mapper. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download wyrihaximus/tactician-job-command-mapper
More information about wyrihaximus/tactician-job-command-mapper
Files in wyrihaximus/tactician-job-command-mapper
Package tactician-job-command-mapper
Short Description Job to Command mapper for Tactician
License MIT
Informations about the package tactician-job-command-mapper
Job to Command mapper intended to be used with Tactician
Install
To install via Composer, use the command below, it will automatically detect the latest version and bind it with ^
.
Set up
When creating a Command
add the @Job
annotation to map it to one or more jobs.
Mapping
The mapper needs two things, a path where it can find commands. From there it scans all classes it finds for the @Job
annotation and stores that map internally
Mapper::map
To add a set of commands simple pass it the path and the mapper will pick up the correct namespaces for you.
Mapper::hasCommand
Check if the map has a command for the job we have.
Mapper::getCommand
Check if the map has a command for the job we have.
Full class example
License
The MIT License (MIT)
Copyright (c) 2019 Cees-Jan Kiewiet
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
All versions of tactician-job-command-mapper with dependencies
doctrine/annotations Version ^1.6
wyrihaximus/doctrine-annotation-autoloader Version ^1.0
wyrihaximus/list-classes-in-directory Version ^1.3