PhpStorm 2019.1 Help

Change Signature Dialog

Refactor | Change Signature


The Change Signature refactoring combines several different modifications that can be applied to a method signature. You can use this refactoring for the following purposes:

  • To change the method name.

  • To change the method return type.

  • To add new parameters and remove the existing ones.

  • To assign default values to the parameters.

  • To reorder parameters.

  • To change parameter names.

  • To propagate new parameters through the method call hierarchy.

When changing a method signature, PhpStorm searches for all usages of the method and updates all the calls, implementations, and override replacements of the method that can be safely modified to reflect the change.

Item

Description

Name

Name of a function, method, or a method specification.

Parameters

List of parameters in the signature. In the Parameters field, you can perform the following actions with parameters:

  • Add (The Add icon): Adds a new parameter. You can specify properties of the new parameter in the corresponding table row (a name, type, and a default value).

  • Remove (The Remove icon): Removes a parameter.

  • Up (The Up icon) and Down (The Down icon) icons: Reorders parameters.

Result parameters

Returned or result parameters of a Go function. You can specify properties of the new parameter in the corresponding table row (a name, type, and a default value).

Last modified: 16 April 2019