本文整理汇总了Java中com.sun.jdi.request.MethodEntryRequest.addClassExclusionFilter方法的典型用法代码示例。如果您正苦于以下问题:Java MethodEntryRequest.addClassExclusionFilter方法的具体用法?Java MethodEntryRequest.addClassExclusionFilter怎么用?Java MethodEntryRequest.addClassExclusionFilter使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.sun.jdi.request.MethodEntryRequest
的用法示例。
在下文中一共展示了MethodEntryRequest.addClassExclusionFilter方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: setEventRequests
import com.sun.jdi.request.MethodEntryRequest; //导入方法依赖的package包/类
/**
* Create the desired event requests, and enable
* them so that we will get events.
* @param excludes Class patterns for which we don't want events
* @param watchFields Do we want to watch assignments to fields
*/
void setEventRequests() {
EventRequestManager mgr = vm.eventRequestManager();
ExceptionRequest excReq = mgr.createExceptionRequest(null,true, true);
excReq.setSuspendPolicy(EventRequest.SUSPEND_ALL);
excReq.enable();
MethodEntryRequest menr = mgr.createMethodEntryRequest();
for (int i=0; i<excludes.size(); ++i) {
menr.addClassExclusionFilter(excludes.get(i));
}
menr.setSuspendPolicy(EventRequest.SUSPEND_ALL);
menr.enable();
MethodExitRequest mexr = mgr.createMethodExitRequest();
for (int i=0; i<excludes.size(); ++i) {
mexr.addClassExclusionFilter(excludes.get(i));
}
mexr.setSuspendPolicy(EventRequest.SUSPEND_ALL);
mexr.enable();
ThreadDeathRequest tdr = mgr.createThreadDeathRequest();
tdr.setSuspendPolicy(EventRequest.SUSPEND_ALL);
tdr.enable();
}
示例2: addExcludes
import com.sun.jdi.request.MethodEntryRequest; //导入方法依赖的package包/类
static void addExcludes(MethodEntryRequest request) {
for (String pattern : excludes()) {
request.addClassExclusionFilter(pattern);
}
}
示例3: addExcludes
import com.sun.jdi.request.MethodEntryRequest; //导入方法依赖的package包/类
void addExcludes(MethodEntryRequest request) {
for (String pattern : excludes()) {
request.addClassExclusionFilter(pattern);
}
}