pull_members_up
MCP tools › Code insight and refactoring
Pull Members Up for the class at (or around) a position of a JavaScript or TypeScript file: moves members to the end of the direct supertype named target (may be left out when there is only one), or adds their signature when it is an interface or abstract is true (an abstract class). dry_run defaults to true and returns the edits per file; dry_run=false writes them. Refuses with the reasons when it cannot.
Its results carry text from files, language_server: the client is told to treat that as data, never as instructions.
| Capability | code.pull_members_up |
|---|---|
| Area | Code insight and refactoring |
| Access | changes files |
| Reaches | process |
| Rights | write |
| Dry run | dry_run, on unless the call turns it off |
Arguments
| Argument | Type | Description |
|---|---|---|
pathrequired | string | Workspace-relative file path. |
linerequired | integer | 0-based line.minimum 0 |
characterrequired | integer | 0-based character in the line (Unicode scalar values).minimum 0 |
target | string | The direct supertype to pull into; may be left out when there is only one. |
membersrequired | array of string | Names of the chosen members. |
abstract | boolean | Declare them abstract in the target and keep the implementations (default false). |
dry_run | boolean | Only report the edits (default true). |
Call it from a shell
ferris-idea call runs one tool with the rights and safe mode of ferris-idea mcp. Replace the folder and the placeholder values.
ferris-idea call ~/my-project pull_members_up '{"path":"<string>","line":1,"character":1,"members":[]}'Input schema as JSON
{ "type": "object", "required": [ "path", "line", "character", "members" ], "properties": { "path": { "description": "Workspace-relative file path.", "type": "string" }, "line": { "description": "0-based line.", "type": "integer", "minimum": 0 }, "character": { "description": "0-based character in the line (Unicode scalar values).", "type": "integer", "minimum": 0 }, "target": { "description": "The direct supertype to pull into; may be left out when there is only one.", "type": [ "string", "null" ] }, "members": { "description": "Names of the chosen members.", "type": "array", "items": { "type": "string" } }, "abstract": { "description": "Declare them abstract in the target and keep the implementations (default false).", "type": [ "boolean", "null" ] }, "dry_run": { "description": "Only report the edits (default true).", "type": [ "boolean", "null" ] } }}