iku*_*sin 4 regex extraction textedit
通常我有以下情况:有一个PONO类,其中包含属性列表.
public string UserName
{
get { return this.userName; }
set { if (this.userName != value) { SetDirty(); this.userName = value; } }
}
public string Password
{
get { return this.password; }
set { if (this.password != value) { SetDirty(); this.password = value; } }
}
public string Email
{
get { return this.email; }
set { if (this.email != value) { SetDirty(); this.email = value; } }
}
public string Title
{
get { return this.title; }
set { if (this.title != value) { SetDirty(); this.title = value; } }
}
Run Code Online (Sandbox Code Playgroud)
是否有工具,最好是Notepad ++或VS插件,将正则表达式输出提取到另一个文件中?
例如:查找:"public string(.*)$"结果:
UserName
Password
Email
Title
Run Code Online (Sandbox Code Playgroud)
在一个新文件中.
在Notepad ++中使用Search/ Find对话框并在Mark选项卡中选中Bookmark line复选框 - Mark all在所有需要的行上都有书签.

最后一步是Search/ Bookmark/ Copy bookmarked lines并将它们粘贴到一个新文件中,您可以在其中删除该public string部分.
从v5.8.7更改日志:
我猜这个Bookmark line复选框Mark all放在v5.8.6的另一个标签中.
| 归档时间: |
|
| 查看次数: |
3382 次 |
| 最近记录: |