ConfigurationCommandController
class ConfigurationCommandController extends CommandController (View source)
Configuration command controller for the Neos.Flow package
Properties
protected Request | $request | from CommandController | |
protected Response | $response | from CommandController | |
protected Arguments | $arguments | from CommandController | |
protected string | $commandMethodName | Name of the command method |
from CommandController |
protected ObjectManagerInterface | $objectManager | from CommandController | |
protected CommandManager | $commandManager | from CommandController | |
protected ConsoleOutput | $output | from CommandController | |
protected ConfigurationManager | $configurationManager | ||
protected ConfigurationSchemaValidator | $configurationSchemaValidator | ||
protected SchemaGenerator | $schemaGenerator |
Methods
Resolves and checks the current command method name
Initializes the arguments array of this controller by creating an empty argument object for each of the method arguments found in the designated command method.
Maps arguments delivered by the request object to the local controller arguments.
Forwards the request to another command and / or CommandController.
Calls the specified command method and passes the arguments.
Returns the CLI Flow command depending on the environment
Outputs specified text to the console window You can specify arguments that will be passed to the text via sprintf
Outputs specified text to the console window and appends a line break
Formats the given text to fit into MAXIMUM_LINE_LENGTH and outputs it to the console window
Exits the CLI through the dispatcher and makes sure that Flow is properly shut down.
Sends the response and exits the CLI without any further code execution Should be used for commands that flush code caches.
Show the active configuration settings
List registered configuration types
Validate the given configuration
Generate a schema for the given configuration or YAML file.
Details
__construct()
Constructs the command controller
void
injectCommandManager(CommandManager $commandManager)
No description
void
injectObjectManager(ObjectManagerInterface $objectManager)
Injects the reflection service
protected string
resolveCommandMethodName()
Resolves and checks the current command method name
Note: The resulting command method name might not have the correct case, which isn't a problem because PHP is case insensitive regarding method names.
protected void
initializeCommandMethodArguments()
Initializes the arguments array of this controller by creating an empty argument object for each of the method arguments found in the designated command method.
protected void
mapRequestArgumentsToControllerArguments()
Maps arguments delivered by the request object to the local controller arguments.
protected void
forward(string $commandName, string $controllerObjectName = null, array $arguments = [])
Forwards the request to another command and / or CommandController.
Request is directly transferred to the other command / controller without the need for a new request.
protected void
callCommandMethod()
Calls the specified command method and passes the arguments.
If the command returns a string, it is appended to the content in the response object. If the command doesn't return anything and a valid view exists, the view is rendered automatically.
string
getFlowInvocationString()
Returns the CLI Flow command depending on the environment
protected void
output(string $text, array $arguments = [])
Outputs specified text to the console window You can specify arguments that will be passed to the text via sprintf
protected void
outputLine(string $text = '', array $arguments = [])
Outputs specified text to the console window and appends a line break
protected void
outputFormatted(string $text = '', array $arguments = [], int $leftPadding = 0)
Formats the given text to fit into MAXIMUM_LINE_LENGTH and outputs it to the console window
protected void
quit(int $exitCode = 0)
Exits the CLI through the dispatcher and makes sure that Flow is properly shut down.
If your command relies on functionality which is triggered through the Bootstrap shutdown (such as the persistence framework), you must use quit() instead of exit().
protected void
sendAndExit(int $exitCode = 0)
Sends the response and exits the CLI without any further code execution Should be used for commands that flush code caches.
void
showCommand(string $type = 'Settings', string $path = null)
Show the active configuration settings
The command shows the configuration of the current context as it is used by Flow itself. You can specify the configuration type and path if you want to show parts of the configuration.
Display all settings: ./flow configuration:show
Display Flow persistence settings: ./flow configuration:show --path Neos.Flow.persistence
Display Flow Object Cache configuration ./flow configuration:show --type Caches --path Flow_Object_Classes
void
listTypesCommand()
List registered configuration types
void
validateCommand(string $type = null, string $path = null, bool $verbose = false)
Validate the given configuration
Validate all configuration ./flow configuration:validate
Validate configuration at a certain subtype ./flow configuration:validate --type Settings --path Neos.Flow.persistence
You can retrieve the available configuration types with: ./flow configuration:listtypes
void
generateSchemaCommand(string $type = null, string $path = null, string $yaml = null)
Generate a schema for the given configuration or YAML file.
./flow configuration:generateschema --type Settings --path Neos.Flow.persistence
The schema will be output to standard output.