【发布时间】:2013-02-11 21:06:33
【问题描述】:
假设我有两个 Java 类,TradeType 和 InstrumentType。我知道在我的代码库的某个地方有一个从 TradeType 映射到 InstrumentType 的方法。
如何在 Intellij 中使用结构搜索来表示
“找到所有具有 TradeType 类型参数并返回 InstrumentType 的方法”
【问题讨论】:
标签: intellij-idea structural-search
假设我有两个 Java 类,TradeType 和 InstrumentType。我知道在我的代码库的某个地方有一个从 TradeType 映射到 InstrumentType 的方法。
如何在 Intellij 中使用结构搜索来表示
“找到所有具有 TradeType 类型参数并返回 InstrumentType 的方法”
【问题讨论】:
标签: intellij-idea structural-search
搜索模板:
class $Class$ {
InstrumentType $MethodName$(TradeType $Parameter$);
}
然后点击Edit variables...,为MethodName变量设置如下:
还要注意搜索的范围是什么。
【讨论】: