Documentation

BracesFixer extends AbstractProxyFixer
in package
implements ConfigurableFixerInterface, WhitespacesAwareFixerInterface, DeprecatedFixerInterface uses ConfigurableFixerTrait

FinalYes

Fixer for rules defined in PSR2 ¶4.1, ¶4.4, ¶5.

Tags
author

Dariusz Rumiński dariusz.ruminski@gmail.com

deprecated
implements

ConfigurableFixerInterface<_AutogeneratedInputConfiguration, _AutogeneratedComputedConfiguration>

phpstan-type

_AutogeneratedInputConfiguration array{ allow_single_line_anonymous_class_with_empty_body?: bool, allow_single_line_closure?: bool, position_after_anonymous_constructs?: 'next'|'same', position_after_control_structures?: 'next'|'same', position_after_functions_and_oop_constructs?: 'next'|'same' }

phpstan-type

_AutogeneratedComputedConfiguration array{ allow_single_line_anonymous_class_with_empty_body: bool, allow_single_line_closure: bool, position_after_anonymous_constructs: 'next'|'same', position_after_control_structures: 'next'|'same', position_after_functions_and_oop_constructs: 'next'|'same' }

Table of Contents

Interfaces

ConfigurableFixerInterface
WhitespacesAwareFixerInterface
DeprecatedFixerInterface

Properties

$bracesPositionFixer  : null|BracesPositionFixer
$controlStructureContinuationPositionFixer  : null|ControlStructureContinuationPositionFixer

Methods

getDefinition()  : FixerDefinitionInterface
Returns the definition of the fixer.
getPriority()  : int
Returns the priority of the fixer.
getSuccessorsNames()  : array<int, string>
Returns names of fixers to use instead, if any.
configurePostNormalisation()  : void
createConfigurationDefinition()  : FixerConfigurationResolverInterface
createProxyFixers()  : array<string|int, mixed>
getBracesPositionFixer()  : BracesPositionFixer
getControlStructureContinuationPositionFixer()  : ControlStructureContinuationPositionFixer
translatePositionOption()  : BracesPositionFixer::NEXT_LINE_UNLESS_NEWLINE_AT_SIGNATURE_END|BracesPositionFixer::SAME_LINE

Properties

Methods

getPriority()

Returns the priority of the fixer.

public getPriority() : int

Must run before HeredocIndentationFixer. Must run after ClassAttributesSeparationFixer, ClassDefinitionFixer, EmptyLoopBodyFixer, NoAlternativeSyntaxFixer, NoEmptyStatementFixer, NoUselessElseFixer, SingleLineThrowFixer, SingleSpaceAfterConstructFixer, SingleSpaceAroundConstructFixer, SingleTraitInsertPerStatementFixer.

Return values
int

getSuccessorsNames()

Returns names of fixers to use instead, if any.

public getSuccessorsNames() : array<int, string>
Return values
array<int, string>

configurePostNormalisation()

protected configurePostNormalisation() : void

createProxyFixers()

protected createProxyFixers() : array<string|int, mixed>
Return values
array<string|int, mixed>

translatePositionOption()

private translatePositionOption(string $option) : BracesPositionFixer::NEXT_LINE_UNLESS_NEWLINE_AT_SIGNATURE_END|BracesPositionFixer::SAME_LINE
Parameters
$option : string
Return values
BracesPositionFixer::NEXT_LINE_UNLESS_NEWLINE_AT_SIGNATURE_END|BracesPositionFixer::SAME_LINE

        
On this page

Search results