package com.chinaweal.aiccs.aiccs.business.rules.model;


import java.util.ArrayList;
import java.util.List;
import java.util.Map;

public class RuleModel {
    private String definedname;
    private String description;
    private boolean independent;
    private Map<String, NodeModel> nodeModelMap;
    private Map<String, SequenceFlowModel> sequenceFlowModelMap;
    private String pdefinedname;
    private String pnodename;
    private String startnodeid;
    private List<String> endnodeids;

    public boolean isIndependent() {
        return independent;
    }

    public void setIndependent(boolean independent) {
        this.independent = independent;
    }

    public String getStartnodeid() {
        return startnodeid;
    }

    public void setStartnodeid(String startnodeid) {
        this.startnodeid = startnodeid;
    }

    public List<String> getEndnodeids() {
        return endnodeids;
    }

    public void setEndnodeid(String endnodeid) {
        if (endnodeids == null) {
            endnodeids = new ArrayList<String>();
        }
        endnodeids.add(endnodeid);
    }

    public String getPdefinedname() {
        return pdefinedname;
    }

    public void setPdefinedname(String pdefinedname) {
        this.pdefinedname = pdefinedname;
    }

    public String getPnodename() {
        return pnodename;
    }

    public void setPnodename(String pnodename) {
        this.pnodename = pnodename;
    }

    public String getDefinedname() {
        return definedname;
    }

    public void setDefinedname(String definedname) {
        this.definedname = definedname;
    }

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public Map<String, NodeModel> getNodeModelMap() {
        return nodeModelMap;
    }

    public void setNodeModelMap(Map<String, NodeModel> nodeModelMap) {
        this.nodeModelMap = nodeModelMap;
    }

    public Map<String, SequenceFlowModel> getSequenceFlowModelMap() {
        return sequenceFlowModelMap;
    }

    public void setSequenceFlowModelMap(Map<String, SequenceFlowModel> sequenceFlowModelMap) {
        this.sequenceFlowModelMap = sequenceFlowModelMap;
    }
}
