001package org.kuali.rice.krms.dto;
002
003import org.kuali.rice.core.api.util.tree.Tree;
004import org.kuali.rice.krad.web.form.UifFormBase;
005import org.kuali.rice.krms.tree.node.CompareTreeNode;
006import org.kuali.rice.krms.tree.node.RuleEditorTreeNode;
007import org.kuali.rice.krms.tree.node.TreeNode;
008
009import java.util.ArrayList;
010import java.util.List;
011
012/**
013 * Created with IntelliJ IDEA.
014 * User: SW
015 * Date: 2013/04/03
016 * Time: 2:09 PM
017 * To change this template use File | Settings | File Templates.
018 */
019public class RuleManagementWrapper extends UifFormBase {
020
021    private String refObjectId;
022    private String selectedRuleId;
023    private String namePrefix;
024    private String namespace;
025
026    private List<AgendaEditor> agendas;
027    private RuleEditor ruleEditor;
028
029    private List<String> deletedRuleIds;
030
031    private Tree<CompareTreeNode, String> compareTree;
032
033    public String getRefObjectId() {
034        return refObjectId;
035    }
036
037    public void setRefObjectId(String refObjectId) {
038        this.refObjectId = refObjectId;
039    }
040
041    public String getSelectedRuleId() {
042        return selectedRuleId;
043    }
044
045    public void setSelectedRuleId(String selectedRuleId) {
046        this.selectedRuleId = selectedRuleId;
047    }
048
049    public List<AgendaEditor> getAgendas() {
050        return agendas;
051    }
052
053    public void setAgendas(List<AgendaEditor> agendas) {
054        this.agendas = agendas;
055    }
056
057    public Tree<CompareTreeNode, String> getCompareTree() {
058        return compareTree;
059    }
060
061    public void setCompareTree(Tree<CompareTreeNode, String> compareTree) {
062        this.compareTree = compareTree;
063    }
064
065    public RuleEditor getRuleEditor() {
066        return ruleEditor;
067    }
068
069    public void setRuleEditor(RuleEditor ruleEditor) {
070        this.ruleEditor = ruleEditor;
071    }
072
073    public Tree<RuleEditorTreeNode, String> getEditTree() {
074        return this.getRuleEditor().getEditTree();
075    }
076
077    public Tree<TreeNode, String> getPreviewTree() {
078        return this.getRuleEditor().getPreviewTree();
079    }
080
081    public Tree<TreeNode, String> getViewTree() {
082       return this.getRuleEditor().getViewTree();
083    }
084
085    public void setActiveSelections(List<String> activeSelections) {
086        this.getRuleEditor().setActiveSelections(activeSelections);
087    }
088
089    public List<String> getActiveSelections(){
090        return this.getRuleEditor().getActiveSelections();
091    }
092
093    public String getSelectedKey() {
094        return this.getRuleEditor().getSelectedKey();
095    }
096
097    public void setSelectedKey(String selectedKey) {
098        this.getRuleEditor().setSelectedKey(selectedKey);
099    }
100
101    public String getCutKey() {
102        return this.getRuleEditor().getCutKey();
103    }
104
105    public void setCutKey(String cutKey) {
106        this.getRuleEditor().setCutKey(cutKey);
107    }
108
109    public String getCopyKey() {
110        return this.getRuleEditor().getCopyKey();
111    }
112
113    public void setCopyKey(String copyKey) {
114        this.getRuleEditor().setCopyKey(copyKey);
115    }
116
117    public String getLogicArea() {
118        return this.getRuleEditor().getLogicArea();
119    }
120
121    public void setLogicArea(String logicArea) {
122        this.getRuleEditor().setLogicArea(logicArea);
123    }
124
125    public String getSelectedTab() {
126        return this.getRuleEditor().getSelectedTab();
127    }
128
129    public void setSelectedTab(String selectedTab) {
130        this.getRuleEditor().setSelectedTab(selectedTab);
131    }
132
133    public List<String> getDeletedRuleIds() {
134        if(this.deletedRuleIds == null) {
135            return deletedRuleIds = new ArrayList<String>();
136        }
137        return deletedRuleIds;
138    }
139
140    public void setDeletedRuleIds(List<String> deletedRuleIds) {
141        this.deletedRuleIds = deletedRuleIds;
142    }
143
144    public String getNamePrefix() {
145        return namePrefix;
146    }
147
148    public void setRulePrefix(String namePrefix) {
149        this.namePrefix = namePrefix;
150    }
151
152    public String getNamespace() {
153        return namespace;
154    }
155
156    public void setNamespace(String namespace) {
157        this.namespace = namespace;
158    }
159}