mirror of https://github.com/apache/lucene.git
refactoring
git-svn-id: https://svn.apache.org/repos/asf/lucene/solr/trunk@816082 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
7bfec227b6
commit
3b90c5eee5
|
@ -54,15 +54,20 @@ public class EntityProcessorBase extends EntityProcessor {
|
|||
public void init(Context context) {
|
||||
rowIterator = null;
|
||||
this.context = context;
|
||||
resolver = (VariableResolverImpl) context.getVariableResolver();
|
||||
if (isFirstInit) {
|
||||
entityName = context.getEntityAttribute("name");
|
||||
String s = context.getEntityAttribute(ON_ERROR);
|
||||
if (s != null) onError = s;
|
||||
firstInit(context);
|
||||
}
|
||||
resolver = (VariableResolverImpl) context.getVariableResolver();
|
||||
query = null;
|
||||
isFirstInit = false;
|
||||
}
|
||||
|
||||
/**first time init call. do one-time operations here
|
||||
*/
|
||||
protected void firstInit(Context context) {
|
||||
entityName = context.getEntityAttribute("name");
|
||||
String s = context.getEntityAttribute(ON_ERROR);
|
||||
if (s != null) onError = s;
|
||||
isFirstInit = false;
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue