PHP 클래스 Neos\Flow\Cli\RequestBuilder

파일 보기 프로젝트 열기: neos/flow-development-collection 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$commandManager CommandManager
$environment Neos\Flow\Utility\Environment
$objectManager Neos\Flow\ObjectManagement\ObjectManagerInterface
$packageManager Neos\Flow\Package\PackageManagerInterface

공개 메소드들

메소드 설명
build ( mixed $commandLine ) : Request Builds a CLI request object from a command line.
injectCommandManager ( CommandManager $commandManager ) : void
injectEnvironment ( Environment $environment ) : void
injectObjectManager ( Neos\Flow\ObjectManagement\ObjectManagerInterface $objectManager ) : void
injectPackageManager ( Neos\Flow\Package\PackageManagerInterface $packageManager ) : void

보호된 메소드들

메소드 설명
extractArgumentNameFromCommandLinePart ( string $commandLinePart ) : string Extracts the option or argument name from the name / value pair of a command line.
getValueOfCurrentCommandLineOption ( string $currentArgument, array &$rawCommandLineArguments, string $expectedArgumentType ) : string Returns the value of the first argument of the given input array. Shifts the parsed argument off the array.
parseRawCommandLineArguments ( array $rawCommandLineArguments, string $controllerObjectName, string $controllerCommandName ) : array Takes an array of unparsed command line arguments and options and converts it separated by named arguments, options and unnamed arguments.

메소드 상세

build() 공개 메소드

The given command line may be a string (e.g. "mypackage:foo do-that-thing --force") or an array consisting of the individual parts. The array must not include the script name (like in $argv) but start with command right away.
public build ( mixed $commandLine ) : Request
$commandLine mixed The command line, either as a string or as an array
리턴 Request The CLI request as an object

extractArgumentNameFromCommandLinePart() 보호된 메소드

Extracts the option or argument name from the name / value pair of a command line.
protected extractArgumentNameFromCommandLinePart ( string $commandLinePart ) : string
$commandLinePart string Part of the command line, e.g. "my-important-option=SomeInterestingValue"
리턴 string The lowercased argument name, e.g. "myimportantoption"

getValueOfCurrentCommandLineOption() 보호된 메소드

Returns the value of the first argument of the given input array. Shifts the parsed argument off the array.
protected getValueOfCurrentCommandLineOption ( string $currentArgument, array &$rawCommandLineArguments, string $expectedArgumentType ) : string
$currentArgument string The current argument
$rawCommandLineArguments array
$expectedArgumentType string The expected type of the current argument, because booleans get special attention
리턴 string The value of the first argument

injectCommandManager() 공개 메소드

public injectCommandManager ( CommandManager $commandManager ) : void
$commandManager CommandManager
리턴 void

injectEnvironment() 공개 메소드

public injectEnvironment ( Environment $environment ) : void
$environment Neos\Flow\Utility\Environment
리턴 void

injectObjectManager() 공개 메소드

public injectObjectManager ( Neos\Flow\ObjectManagement\ObjectManagerInterface $objectManager ) : void
$objectManager Neos\Flow\ObjectManagement\ObjectManagerInterface
리턴 void

injectPackageManager() 공개 메소드

public injectPackageManager ( Neos\Flow\Package\PackageManagerInterface $packageManager ) : void
$packageManager Neos\Flow\Package\PackageManagerInterface
리턴 void

parseRawCommandLineArguments() 보호된 메소드

Takes an array of unparsed command line arguments and options and converts it separated by named arguments, options and unnamed arguments.
protected parseRawCommandLineArguments ( array $rawCommandLineArguments, string $controllerObjectName, string $controllerCommandName ) : array
$rawCommandLineArguments array The unparsed command parts (such as "--foo") as an array
$controllerObjectName string Object name of the designated command controller
$controllerCommandName string Command name of the recognized command (ie. method name without "Command" suffix)
리턴 array All and exceeding command line arguments

프로퍼티 상세

$commandManager 보호되어 있는 프로퍼티

protected CommandManager,Neos\Flow\Cli $commandManager
리턴 CommandManager

$environment 보호되어 있는 프로퍼티

protected Environment,Neos\Flow\Utility $environment
리턴 Neos\Flow\Utility\Environment

$objectManager 보호되어 있는 프로퍼티

protected ObjectManagerInterface,Neos\Flow\ObjectManagement $objectManager
리턴 Neos\Flow\ObjectManagement\ObjectManagerInterface

$packageManager 보호되어 있는 프로퍼티

protected PackageManagerInterface,Neos\Flow\Package $packageManager
리턴 Neos\Flow\Package\PackageManagerInterface