blob: 5eeaa8864e95f78570a94470ade8706515049629 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
package com.yahoo.vespa.model.container.search.searchchain;
import com.yahoo.component.chain.model.ChainedComponentModel;
import com.yahoo.config.model.producer.TreeConfigProducer;
import com.yahoo.vespa.model.container.component.chain.ChainedComponent;
/**
* @author gjoranv
* @author Tony Vaagenes
*/
public class Searcher<T extends ChainedComponentModel> extends ChainedComponent<T> {
public Searcher(T model) {
super(model);
}
protected SearchChains getSearchChains() {
var ancestor = getParent();
while (!(ancestor instanceof SearchChains)) {
ancestor = ancestor.getParent();
}
return (SearchChains)ancestor;
}
}
|