Class EditOperation
Represents a single edit operation within ScriptApplyEditsParams
Inherited Members
Namespace: Unity.AI.MCP.Editor.Tools.Parameters
Assembly: Unity.AI.MCP.Editor.dll
Syntax
[Serializable]
public class EditOperation
Properties
AfterMethodName
Method name to insert after (when position = "after")
Declaration
public string AfterMethodName { get; set; }
Property Value
| Type | Description |
|---|---|
| string |
AllowNoop
Whether to allow no-op if anchor is not found
Declaration
public bool AllowNoop { get; set; }
Property Value
| Type | Description |
|---|---|
| bool |
Anchor
Regex pattern for anchor operations
Declaration
public string Anchor { get; set; }
Property Value
| Type | Description |
|---|---|
| string |
AttributesContains
Attributes filter for method operations
Declaration
public string AttributesContains { get; set; }
Property Value
| Type | Description |
|---|---|
| string |
BeforeMethodName
Method name to insert before (when position = "before")
Declaration
public string BeforeMethodName { get; set; }
Property Value
| Type | Description |
|---|---|
| string |
ClassName
Class name for method/class operations
Declaration
public string ClassName { get; set; }
Property Value
| Type | Description |
|---|---|
| string |
Count
Count for regex replace (0 = replace all)
Declaration
public int Count { get; set; }
Property Value
| Type | Description |
|---|---|
| int |
EndCol
Ending column number for replace_range operations
Declaration
public int EndCol { get; set; }
Property Value
| Type | Description |
|---|---|
| int |
EndLine
Ending line number for replace_range operations
Declaration
public int EndLine { get; set; }
Property Value
| Type | Description |
|---|---|
| int |
IgnoreCase
Whether to ignore case in pattern matching
Declaration
public bool IgnoreCase { get; set; }
Property Value
| Type | Description |
|---|---|
| bool |
MethodName
Method name for method operations
Declaration
public string MethodName { get; set; }
Property Value
| Type | Description |
|---|---|
| string |
Namespace
Namespace for class operations
Declaration
public string Namespace { get; set; }
Property Value
| Type | Description |
|---|---|
| string |
Op
The operation type: replace_method, insert_method, delete_method, anchor_insert, anchor_delete, anchor_replace, prepend, append, replace_range, regex_replace
Declaration
public string Op { get; set; }
Property Value
| Type | Description |
|---|---|
| string |
ParametersSignature
Parameters signature filter for method operations
Declaration
public string ParametersSignature { get; set; }
Property Value
| Type | Description |
|---|---|
| string |
Pattern
Pattern for regex operations
Declaration
public string Pattern { get; set; }
Property Value
| Type | Description |
|---|---|
| string |
Position
Position for insert operations: start, end, after, before
Declaration
public string Position { get; set; }
Property Value
| Type | Description |
|---|---|
| string |
PreferLast
Whether to prefer the last match over the first (for anchor operations)
Declaration
public bool PreferLast { get; set; }
Property Value
| Type | Description |
|---|---|
| bool |
Replacement
Replacement text for replace operations
Declaration
public string Replacement { get; set; }
Property Value
| Type | Description |
|---|---|
| string |
ReturnType
Return type filter for method operations
Declaration
public string ReturnType { get; set; }
Property Value
| Type | Description |
|---|---|
| string |
StartCol
Starting column number for replace_range operations
Declaration
public int StartCol { get; set; }
Property Value
| Type | Description |
|---|---|
| int |
StartLine
Starting line number for replace_range operations
Declaration
public int StartLine { get; set; }
Property Value
| Type | Description |
|---|---|
| int |
Text
Text to insert/replace for anchor operations
Declaration
public string Text { get; set; }
Property Value
| Type | Description |
|---|---|
| string |