package de.tblsoft.solr.pipeline.bean;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 * Created by tblsoft on 22.01.16.
 */
public class Pipeline {
    private String name;

    private String processId;

    private String webHookStart;

    private String webHookEnd;

    private Map<String,String> variables = new HashMap<String, String>();

    private Reader reader;
    private List<Filter> filter;

    private List<Processor> preProcessor;

    private List<Processor> postProcessor;

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Reader getReader() {
        return reader;
    }

    public void setReader(Reader reader) {
        this.reader = reader;
    }

    public List<Filter> getFilter() {
        return filter;
    }

    public void setFilter(List<Filter> filter) {
        this.filter = filter;
    }

    public Map<String, String> getVariables() {
        return variables;
    }

    public void setVariables(Map<String, String> variables) {
        this.variables = variables;
    }


    public List<Processor> getPreProcessor() {
        return preProcessor;
    }

    public void setPreProcessor(List<Processor> preProcessor) {
        this.preProcessor = preProcessor;
    }

    public List<Processor> getPostProcessor() {
        return postProcessor;
    }

    public void setPostProcessor(List<Processor> postProcessor) {
        this.postProcessor = postProcessor;
    }

    public String getProcessId() {
        return processId;
    }

    public void setProcessId(String processId) {
        this.processId = processId;
    }

    public String getWebHookStart() {
        return webHookStart;
    }

    public void setWebHookStart(String webHookStart) {
        this.webHookStart = webHookStart;
    }

    public String getWebHookEnd() {
        return webHookEnd;
    }

    public void setWebHookEnd(String webHookEnd) {
        this.webHookEnd = webHookEnd;
    }

    @Override
    public String toString() {
        return "Pipeline{" +
                "name='" + name + '\'' +
                ", variables=" + variables +
                ", reader=" + reader +
                ", filter=" + filter +
                '}';
    }
}

@@ -2029,24 +2029,25 @@
 End;%0A    %7D%0A%0A
+%0A
     @Overrid
@@ -2172,108 +2172,379 @@
  %22, 
-variables=%22 + variables +%0A                %22, reader=%22 + reader +%0A                %22, filter=%22 + filte
+processId='%22 + processId + '%5C'' +%0A                %22, webHookStart='%22 + webHookStart + '%5C'' +%0A                %22, webHookEnd='%22 + webHookEnd + '%5C'' +%0A                %22, variables=%22 + variables +%0A                %22, reader=%22 + reader +%0A                %22, filter=%22 + filter +%0A                %22, preProcessor=%22 + preProcessor +%0A                %22, postProcessor=%22 + postProcesso
 r +%0A

improve toString method