Neos.ContentRepository/Classes/Command/NodeCommandControllerPlugin.php
public function invokeSubCommand($controllerCommandName, ConsoleOutput $output, NodeType $nodeType = null, $workspaceName = 'live', $dryRun = false, $cleanup = true, $skip = null, $only = null)
    {
        /** @noinspection PhpDeprecationInspection This is only set for backwards compatibility */
        $this->output = $output;
        $commandMethods = [
            'removeAbstractAndUndefinedNodes' => [ 'cleanup' => true ],
            'removeOrphanNodes' => [ 'cleanup' => true ],
            'removeDisallowedChildNodes' => [ 'cleanup' => true ],
            'removeUndefinedProperties' => [ 'cleanup' => true ],
            'removeBrokenEntityReferences' => [ 'cleanup' => true ],
            'removeNodesWithInvalidDimensions' => [ 'cleanup' => true ],
            'removeNodesWithInvalidWorkspace' => [ 'cleanup' => true ],
            'fixNodesWithInconsistentIdentifier' => [ 'cleanup' => false ],
            'createMissingChildNodes' => [ 'cleanup' => false ],
            'reorderChildNodes' => [ 'cleanup' => false ],
            'addMissingDefaultValues' => [ 'cleanup' => false ],
            'repairShadowNodes' => [ 'cleanup' => false ]
        ];
        $skipCommandNames = Arrays::trimExplode(',', ($skip === null ? '' : $skip));
        $onlyCommandNames = Arrays::trimExplode(',', ($only === null ? '' : $only));

        switch ($controllerCommandName) {
            case 'repair':
                foreach ($commandMethods as $commandMethodName => $commandMethodConfiguration) {
                    if (in_array($commandMethodName, $skipCommandNames)) {
                        continue;
                    }
                    if ($onlyCommandNames !== [] && !in_array($commandMethodName, $onlyCommandNames)) {
                        continue;
                    }
                    if (!$cleanup && $commandMethodConfiguration['cleanup']) {
                        continue;
                    }
                    $this->$commandMethodName($workspaceName, $dryRun, $nodeType);
                }
        }
    }
public function invokeSubCommand($controllerCommandName, ConsoleOutput $output, NodeType $nodeType = null, $workspaceName = 'live', $dryRun = false, $cleanup = true, $skip = null, $only = null)
    {
        /** @noinspection PhpDeprecationInspection This is only set for backwards compatibility */
        $this->output = $output;
        $commandMethods = [
            'removeAbstractAndUndefinedNodes' => [ 'cleanup' => true ],
            'removeOrphanNodes' => [ 'cleanup' => true ],
            'removeDisallowedChildNodes' => [ 'cleanup' => true ],
            'removeUndefinedProperties' => [ 'cleanup' => true ],
            'removeBrokenEntityReferences' => [ 'cleanup' => true ],
            'removeNodesWithInvalidDimensions' => [ 'cleanup' => true ],
            'removeNodesWithInvalidWorkspace' => [ 'cleanup' => true ],
            'fixNodesWithInconsistentIdentifier' => [ 'cleanup' => false ],
            'createMissingChildNodes' => [ 'cleanup' => false ],
            'reorderChildNodes' => [ 'cleanup' => false ],
            'addMissingDefaultValues' => [ 'cleanup' => false ],
            'repairShadowNodes' => [ 'cleanup' => false ]
        ];
        $skipCommandNames = Arrays::trimExplode(',', ($skip === null ? '' : $skip));
        $onlyCommandNames = Arrays::trimExplode(',', ($only === null ? '' : $only));

        switch ($controllerCommandName) {
            case 'repair':
                foreach ($commandMethods as $commandMethodName => $commandMethodConfiguration) {
                    if (in_array($commandMethodName, $skipCommandNames)) {
                        continue;
                    }
                    if ($onlyCommandNames !== [] && !in_array($commandMethodName, $onlyCommandNames)) {
                        continue;
                    }
                    if (!$cleanup && $commandMethodConfiguration['cleanup']) {
                        continue;
                    }
                    $this->$commandMethodName($workspaceName, $dryRun, $nodeType);
                }
        }
    }
public function invokeSubCommand ( $ controllerCommandName , ConsoleOutput $ output , NodeType $ nodeType = null , $ workspaceName = 'live' , $ dryRun = false , $ cleanup = true , $ skip = null , $ only = null ) { /** @noinspection PhpDeprecationInspection This is only set for backwards compatibility */ $ this -> output = $ output ; $ commandMethods = [ 'removeAbstractAndUndefinedNodes' => [ 'cleanup' => true ] , 'removeOrphanNodes' => [ 'cleanup' => true ] , 'removeDisallowedChildNodes' => [ 'cleanup' => true ] , 'removeUndefinedProperties' => [ 'cleanup' => true ] , 'removeBrokenEntityReferences' => [ 'cleanup' => true ] , 'removeNodesWithInvalidDimensions' => [ 'cleanup' => true ] , 'removeNodesWithInvalidWorkspace' => [ 'cleanup' => true ] , 'fixNodesWithInconsistentIdentifier' => [ 'cleanup' => false ] , 'createMissingChildNodes' => [ 'cleanup' => false ] , 'reorderChildNodes' => [ 'cleanup' => false ] , 'addMissingDefaultValues' => [ 'cleanup' => false ] , 'repairShadowNodes' => [ 'cleanup' => false ] ] ; $ skipCommandNames = Arrays :: trimExplode ( ',' , ( $ skip === null ? '' : $ skip ) ) ; $ onlyCommandNames = Arrays :: trimExplode ( ',' , ( $ only === null ? '' : $ only ) ) ; switch ( $ controllerCommandName ) { case 'repair' : foreach ( $ commandMethods as $ commandMethodName => $ commandMethodConfiguration ) { if ( in_array ( $ commandMethodName , $ skipCommandNames ) ) { continue ; } if ( $ onlyCommandNames !== [ ] && ! in_array ( $ commandMethodName , $ onlyCommandNames ) ) { continue ; } if ( ! $ cleanup && $ commandMethodConfiguration [ 'cleanup' ] ) { continue ; } $ this -> $ commandMethodName ( $ workspaceName , $ dryRun , $ nodeType ) ; } } }
A method which runs the task implemented by the plugin for the given command

@param string $controllerCommandName Name of the command in question, for example "repair"
@param ConsoleOutput $output (unused)
@param NodeType $nodeType Only handle this node type (if specified)
@param string $workspaceName Only handle this workspace (if specified)
@param boolean $dryRun If true, don't do any changes, just simulate what you would do
@param boolean $cleanup If false, cleanup tasks are skipped
@param string $skip Skip the given check or checks (comma separated)
@param string $only Only execute the given check or checks (comma separated)
@return void
A method which runs the task implemented by the plugin for the given command