Search in sources :

Example 1 with SearchableHttpPanelView

use of org.zaproxy.zap.extension.search.SearchableHttpPanelView in project zaproxy by zaproxy.

the class HttpPanelComponentViewsManager method findSearchableView.

private SearchableHttpPanelView findSearchableView() {
    SearchableHttpPanelView searchableView = null;
    Iterator<HttpPanelView> it = views.values().iterator();
    while (it.hasNext()) {
        HttpPanelView view = it.next();
        if (view.isEnabled(message)) {
            if (view instanceof SearchableHttpPanelView) {
                searchableView = (SearchableHttpPanelView) view;
                break;
            }
        }
    }
    return searchableView;
}
Also used : HttpPanelView(org.zaproxy.zap.extension.httppanel.view.HttpPanelView) SearchableHttpPanelView(org.zaproxy.zap.extension.search.SearchableHttpPanelView) SearchableHttpPanelView(org.zaproxy.zap.extension.search.SearchableHttpPanelView)

Example 2 with SearchableHttpPanelView

use of org.zaproxy.zap.extension.search.SearchableHttpPanelView in project zaproxy by zaproxy.

the class HttpPanelComponentViewsManager method highlight.

public void highlight(SearchMatch sm) {
    if (currentView instanceof SearchableHttpPanelView) {
        ((SearchableHttpPanelView) currentView).highlight(sm);
    } else {
        SearchableHttpPanelView searchableView = findSearchableView();
        if (currentView != null) {
            switchView(((HttpPanelView) searchableView).getName());
            searchableView.highlight(sm);
        }
    }
}
Also used : SearchableHttpPanelView(org.zaproxy.zap.extension.search.SearchableHttpPanelView)

Aggregations

SearchableHttpPanelView (org.zaproxy.zap.extension.search.SearchableHttpPanelView)2 HttpPanelView (org.zaproxy.zap.extension.httppanel.view.HttpPanelView)1