KMP PHP API Reference

BakeQueueTaskCommand extends SimpleBakeCommand
in package

Command class for generating queue task files and their tests.

Table of Contents

Properties

$pathFragment  : string
Task name used in path generation.
$_name  : string

Methods

bake()  : void
bakeTest()  : void
Generate a test case.
buildOptionParser()  : ConsoleOptionParser
Gets the option parser instance and configures it.
defaultName()  : string
fileName()  : string
name()  : string
template()  : string
templateData()  : array<string|int, mixed>
generateTaskTestContent()  : string

Properties

$pathFragment

Task name used in path generation.

public string $pathFragment = 'Queue/Task/'

Methods

bake()

public bake(string $name, Arguments $args, ConsoleIo $io) : void
Parameters
$name : string
$args : Arguments
$io : ConsoleIo
Tags
inheritDoc

bakeTest()

Generate a test case.

public bakeTest(string $name, Arguments $args, ConsoleIo $io) : void
Parameters
$name : string

The class to bake a test for.

$args : Arguments

The console arguments

$io : ConsoleIo

The console io

buildOptionParser()

Gets the option parser instance and configures it.

public buildOptionParser(ConsoleOptionParser $parser) : ConsoleOptionParser
Parameters
$parser : ConsoleOptionParser

Parser instance

Return values
ConsoleOptionParser

fileName()

public fileName(string $name) : string
Parameters
$name : string
Tags
inheritDoc
Return values
string

templateData()

public templateData(Arguments $arguments) : array<string|int, mixed>
Parameters
$arguments : Arguments
Tags
inheritDoc
Return values
array<string|int, mixed>

generateTaskTestContent()

protected generateTaskTestContent(string $name, string $namespace) : string
Parameters
$name : string
$namespace : string
Return values
string

        
On this page

Search results