Coverage Report - org.kuali.rice.kew.rule.RuleBaseValues
 
Classes in this File Line Coverage Branch Coverage Complexity
RuleBaseValues
0%
0/231
0%
0/88
1.6
 
 1  
 /*
 2  
  * Copyright 2005-2007 The Kuali Foundation
 3  
  *
 4  
  *
 5  
  * Licensed under the Educational Community License, Version 2.0 (the "License");
 6  
  * you may not use this file except in compliance with the License.
 7  
  * You may obtain a copy of the License at
 8  
  *
 9  
  * http://www.opensource.org/licenses/ecl2.php
 10  
  *
 11  
  * Unless required by applicable law or agreed to in writing, software
 12  
  * distributed under the License is distributed on an "AS IS" BASIS,
 13  
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 14  
  * See the License for the specific language governing permissions and
 15  
  * limitations under the License.
 16  
  */
 17  
 package org.kuali.rice.kew.rule;
 18  
 
 19  
 import org.hibernate.annotations.Fetch;
 20  
 import org.hibernate.annotations.FetchMode;
 21  
 import org.hibernate.annotations.GenericGenerator;
 22  
 import org.hibernate.annotations.Parameter;
 23  
 import org.kuali.rice.core.api.util.RiceConstants;
 24  
 import org.kuali.rice.kew.doctype.bo.DocumentType;
 25  
 import org.kuali.rice.kew.lookupable.MyColumns;
 26  
 import org.kuali.rice.kew.routeheader.DocumentContent;
 27  
 import org.kuali.rice.kew.rule.bo.RuleAttribute;
 28  
 import org.kuali.rice.kew.rule.bo.RuleTemplate;
 29  
 import org.kuali.rice.kew.rule.bo.RuleTemplateAttribute;
 30  
 import org.kuali.rice.kew.rule.service.RuleService;
 31  
 import org.kuali.rice.kew.rule.xmlrouting.GenericXMLRuleAttribute;
 32  
 import org.kuali.rice.kew.service.KEWServiceLocator;
 33  
 import org.kuali.rice.kew.util.CodeTranslator;
 34  
 import org.kuali.rice.kew.util.KEWConstants;
 35  
 import org.kuali.rice.kim.bo.impl.PersonImpl;
 36  
 import org.kuali.rice.kns.web.ui.Field;
 37  
 import org.kuali.rice.kns.web.ui.Row;
 38  
 import org.kuali.rice.krad.bo.PersistableBusinessObjectBase;
 39  
 import org.springframework.util.AutoPopulatingList;
 40  
 
 41  
 import javax.persistence.CascadeType;
 42  
 import javax.persistence.Column;
 43  
 import javax.persistence.Entity;
 44  
 import javax.persistence.FetchType;
 45  
 import javax.persistence.GeneratedValue;
 46  
 import javax.persistence.Id;
 47  
 import javax.persistence.JoinColumn;
 48  
 import javax.persistence.ManyToOne;
 49  
 import javax.persistence.OneToMany;
 50  
 import javax.persistence.OneToOne;
 51  
 import javax.persistence.Table;
 52  
 import javax.persistence.Transient;
 53  
 import java.sql.Timestamp;
 54  
 import java.util.ArrayList;
 55  
 import java.util.Date;
 56  
 import java.util.HashMap;
 57  
 import java.util.Iterator;
 58  
 import java.util.List;
 59  
 import java.util.Map;
 60  
 
 61  
 /*import org.kuali.rice.kim.api.group.Group;*/
 62  
 
 63  
 
 64  
 /**
 65  
  * A model bean for a Rule within the KEW rules engine.
 66  
  *
 67  
  * @author Kuali Rice Team (rice.collab@kuali.org)
 68  
  */
 69  
 @Entity
 70  
 @Table(name="KREW_RULE_T")
 71  
 //@Sequence(name="KREW_RTE_TMPL_S", property="ruleBaseValuesId")
 72  
 public class RuleBaseValues extends PersistableBusinessObjectBase {
 73  
 
 74  
     private static final long serialVersionUID = 6137765574728530156L;
 75  
     @Id
 76  
     @GeneratedValue(generator="KREW_RTE_TMPL_S")
 77  
         @GenericGenerator(name="KREW_RTE_TMPL_S",strategy="org.hibernate.id.enhanced.SequenceStyleGenerator",parameters={
 78  
                         @Parameter(name="sequence_name",value="KREW_RTE_TMPL_S"),
 79  
                         @Parameter(name="value_column",value="id")
 80  
         })
 81  
         @Column(name="RULE_ID")
 82  
     private String ruleBaseValuesId;
 83  
     /**
 84  
      * Unique Rule name
 85  
      */
 86  
     @Column(name="NM")
 87  
         private String name;
 88  
     @Column(name="RULE_TMPL_ID", insertable=false, updatable=false)
 89  
         private String ruleTemplateId;
 90  
     @Column(name="PREV_RULE_VER_NBR")
 91  
         private String previousVersionId;
 92  
     @Column(name="ACTV_IND")
 93  
         private Boolean activeInd;
 94  
     @Column(name="RULE_BASE_VAL_DESC")
 95  
         private String description;
 96  
     @Column(name="DOC_TYP_NM")
 97  
         private String docTypeName;
 98  
     @Column(name="DOC_HDR_ID")
 99  
         private String documentId;
 100  
         @Column(name="FRM_DT")
 101  
         private Timestamp fromDate;
 102  
         @Column(name="TO_DT")
 103  
         private Timestamp toDate;
 104  
         @Column(name="DACTVN_DT")
 105  
         private Timestamp deactivationDate;
 106  
     @Column(name="CUR_IND")
 107  
         private Boolean currentInd;
 108  
     @Column(name="RULE_VER_NBR")
 109  
         private Integer versionNbr;
 110  
     @Column(name="FRC_ACTN")
 111  
         private Boolean forceAction;
 112  
     @Fetch(value = FetchMode.SELECT)
 113  
     @OneToMany(fetch=FetchType.EAGER,cascade={CascadeType.PERSIST, CascadeType.REMOVE, CascadeType.MERGE},mappedBy="ruleBaseValues")
 114  
         private List<RuleResponsibility> responsibilities;
 115  
     @Fetch(value = FetchMode.SELECT)
 116  
     @OneToMany(fetch=FetchType.EAGER,cascade={CascadeType.PERSIST, CascadeType.REMOVE, CascadeType.MERGE},mappedBy="ruleBaseValues")
 117  
         private List<RuleExtension> ruleExtensions;
 118  
     @ManyToOne(fetch=FetchType.EAGER)
 119  
         @JoinColumn(name="RULE_TMPL_ID")
 120  
         private RuleTemplate ruleTemplate;
 121  
     @OneToOne(fetch=FetchType.EAGER, cascade={CascadeType.PERSIST, CascadeType.REMOVE, CascadeType.MERGE})
 122  
         @JoinColumn(name="RULE_EXPR_ID")
 123  
         private RuleExpressionDef ruleExpressionDef;
 124  
     @Transient
 125  
     private RuleBaseValues previousVersion;
 126  
     @Column(name="ACTVN_DT")
 127  
         private Timestamp activationDate;
 128  0
     @Column(name="DLGN_IND")
 129  
     private Boolean delegateRule = Boolean.FALSE;
 130  
     /**
 131  
      * Indicator that signifies that this rule is a defaults/template rule which contains
 132  
      * template-defined rule defaults for other rules which use the associated template
 133  
      */
 134  0
     @Column(name="TMPL_RULE_IND")
 135  
     private Boolean templateRuleInd = Boolean.FALSE;
 136  
 
 137  
     // required to be lookupable
 138  
     @Transient
 139  
     private String returnUrl;
 140  
     @Transient
 141  
     private String destinationUrl;
 142  
     @Transient
 143  
     private MyColumns myColumns;
 144  
     @Transient
 145  
     private List<PersonRuleResponsibility> personResponsibilities;
 146  
     @Transient
 147  
     private List<GroupRuleResponsibility> groupResponsibilities;
 148  
     @Transient
 149  
     private List<RoleRuleResponsibility> roleResponsibilities;
 150  
     @Transient
 151  
     private Map<String, String> fieldValues;
 152  
     @Transient
 153  
     private String groupReviewerName;
 154  
     @Transient
 155  
     private String groupReviewerNamespace;
 156  
     @Transient
 157  
     private String personReviewer;
 158  
     @Transient
 159  
     private String personReviewerType;
 160  
 
 161  0
     public RuleBaseValues() {
 162  0
         responsibilities = new ArrayList<RuleResponsibility>();
 163  0
         ruleExtensions = new ArrayList<RuleExtension>();
 164  0
         personResponsibilities = new AutoPopulatingList(PersonRuleResponsibility.class);
 165  0
         groupResponsibilities = new AutoPopulatingList(GroupRuleResponsibility.class);
 166  0
         roleResponsibilities = new AutoPopulatingList(RoleRuleResponsibility.class);
 167  0
         fieldValues = new HashMap<String, String>();
 168  0
     }
 169  
 
 170  
     /**
 171  
      * @return the rule expression definition for this rule, if defined
 172  
      */
 173  
     public RuleExpressionDef getRuleExpressionDef() {
 174  0
         return ruleExpressionDef;
 175  
     }
 176  
 
 177  
     /**
 178  
      * @param ruleExpressionDef the rule expression definition to set for this rule
 179  
      */
 180  
     public void setRuleExpressionDef(RuleExpressionDef ruleExpressionDef) {
 181  0
         this.ruleExpressionDef = ruleExpressionDef;
 182  0
     }
 183  
 
 184  
     public Map getRuleExtensionValueLabels() {
 185  0
         Map extensionLabels = new HashMap();
 186  0
         for (Iterator iterator2 = getRuleExtensions().iterator(); iterator2.hasNext();) {
 187  0
             RuleExtension ruleExtension = (RuleExtension) iterator2.next();
 188  0
             if (!ruleExtension.getRuleTemplateAttribute().isWorkflowAttribute()) {
 189  0
                 continue;
 190  
             }
 191  0
             WorkflowAttribute workflowAttribute = ruleExtension.getRuleTemplateAttribute().getWorkflowAttribute();
 192  
 
 193  0
             RuleAttribute ruleAttribute = ruleExtension.getRuleTemplateAttribute().getRuleAttribute();
 194  0
             if (ruleAttribute.getType().equals(KEWConstants.RULE_XML_ATTRIBUTE_TYPE)) {
 195  0
                 ((GenericXMLRuleAttribute) workflowAttribute).setRuleAttribute(ruleAttribute);
 196  
             }
 197  0
             for (Iterator iterator = workflowAttribute.getRuleRows().iterator(); iterator.hasNext();) {
 198  0
                 Row row = (Row) iterator.next();
 199  0
                 for (Iterator iterator3 = row.getFields().iterator(); iterator3.hasNext();) {
 200  0
                     Field field = (Field) iterator3.next();
 201  0
                     if (ruleAttribute.getType().equals(KEWConstants.RULE_XML_ATTRIBUTE_TYPE)) {
 202  0
                         extensionLabels.put(field.getPropertyName(), field.getFieldLabel());
 203  
                     //} else if (!org.apache.commons.lang.StringUtils.isEmpty(field.getDefaultLookupableName())) {
 204  
                     //    extensionLabels.put(field.getDefaultLookupableName(), field.getFieldLabel());
 205  
                     } else {
 206  0
                         extensionLabels.put(field.getPropertyName(), field.getFieldLabel());
 207  
                     }
 208  0
                 }
 209  0
             }
 210  0
         }
 211  0
         return extensionLabels;
 212  
     }
 213  
 
 214  
     public String getRuleTemplateName() {
 215  0
         if (ruleTemplate != null) {
 216  0
             return ruleTemplate.getName();
 217  
         }
 218  0
         return null;
 219  
     }
 220  
 
 221  
     public RuleBaseValues getPreviousVersion() {
 222  0
         if (previousVersion == null && previousVersionId != null) {
 223  0
             RuleService ruleService = (RuleService) KEWServiceLocator.getService(KEWServiceLocator.RULE_SERVICE);
 224  0
             return ruleService.findRuleBaseValuesById(previousVersionId);
 225  
         }
 226  0
         return previousVersion;
 227  
     }
 228  
 
 229  
     public void setPreviousVersion(RuleBaseValues previousVersion) {
 230  0
         this.previousVersion = previousVersion;
 231  0
     }
 232  
 
 233  
     public RuleResponsibility getResponsibility(int index) {
 234  0
         while (getResponsibilities().size() <= index) {
 235  0
             RuleResponsibility ruleResponsibility = new RuleResponsibility();
 236  0
             ruleResponsibility.setRuleBaseValues(this);
 237  0
             getResponsibilities().add(ruleResponsibility);
 238  0
         }
 239  0
         return (RuleResponsibility) getResponsibilities().get(index);
 240  
     }
 241  
 
 242  
     public RuleExtension getRuleExtension(int index) {
 243  0
         while (getRuleExtensions().size() <= index) {
 244  0
             getRuleExtensions().add(new RuleExtension());
 245  
         }
 246  0
         return (RuleExtension) getRuleExtensions().get(index);
 247  
     }
 248  
 
 249  
     public RuleExtensionValue getRuleExtensionValue(String key) {
 250  0
         for (Iterator iter = getRuleExtensions().iterator(); iter.hasNext();) {
 251  0
             RuleExtension ruleExtension = (RuleExtension) iter.next();
 252  0
             for (Iterator iterator = ruleExtension.getExtensionValues().iterator(); iterator.hasNext();) {
 253  0
                 RuleExtensionValue ruleExtensionValue = (RuleExtensionValue) iterator.next();
 254  0
                 if (ruleExtensionValue.getKey().equals(key)) {
 255  0
                     return ruleExtensionValue;
 256  
                 }
 257  0
             }
 258  0
         }
 259  0
         return null;
 260  
     }
 261  
 
 262  
     public RuleExtensionValue getRuleExtensionValue(String ruleTemplateAttributeId, String key) {
 263  0
         for (Iterator iter = getRuleExtensions().iterator(); iter.hasNext();) {
 264  0
             RuleExtension ruleExtension = (RuleExtension) iter.next();
 265  0
             if (ruleExtension.getRuleTemplateAttributeId().equals(ruleTemplateAttributeId)) {
 266  0
                 for (Iterator iterator = ruleExtension.getExtensionValues().iterator(); iterator.hasNext();) {
 267  0
                     RuleExtensionValue ruleExtensionValue = (RuleExtensionValue) iterator.next();
 268  0
                     if (ruleExtensionValue.getKey().equals(key)) {
 269  0
                         return ruleExtensionValue;
 270  
                     }
 271  0
                 }
 272  
             }
 273  0
         }
 274  0
         return null;
 275  
     }
 276  
 
 277  
     public String getPreviousVersionId() {
 278  0
         return previousVersionId;
 279  
     }
 280  
 
 281  
     public void setPreviousVersionId(String previousVersion) {
 282  0
         this.previousVersionId = previousVersion;
 283  0
     }
 284  
 
 285  
     public void addRuleResponsibility(RuleResponsibility ruleResponsibility) {
 286  0
         addRuleResponsibility(ruleResponsibility, new Integer(getResponsibilities().size()));
 287  0
     }
 288  
 
 289  
     public void addRuleResponsibility(RuleResponsibility ruleResponsibility, Integer counter) {
 290  0
         boolean alreadyAdded = false;
 291  0
         int location = 0;
 292  0
         if (counter != null) {
 293  0
             for (Iterator responsibilitiesIter = getResponsibilities().iterator(); responsibilitiesIter.hasNext();) {
 294  0
                 RuleResponsibility ruleResponsibilityRow = (RuleResponsibility) responsibilitiesIter.next();
 295  0
                 if (counter.intValue() == location) {
 296  0
                     ruleResponsibilityRow.setPriority(ruleResponsibility.getPriority());
 297  0
                     ruleResponsibilityRow.setActionRequestedCd(ruleResponsibility.getActionRequestedCd());
 298  0
                     ruleResponsibilityRow.setVersionNumber(ruleResponsibility.getVersionNumber());
 299  0
                     ruleResponsibilityRow.setRuleBaseValuesId(ruleResponsibility.getRuleBaseValuesId());
 300  0
                     ruleResponsibilityRow.setRuleResponsibilityName(ruleResponsibility.getRuleResponsibilityName());
 301  0
                     ruleResponsibilityRow.setRuleResponsibilityType(ruleResponsibility.getRuleResponsibilityType());
 302  
                     //ruleResponsibilityRow.setDelegationRules(ruleResponsibility.getDelegationRules());
 303  0
                     ruleResponsibilityRow.setApprovePolicy(ruleResponsibility.getApprovePolicy());
 304  0
                     alreadyAdded = true;
 305  
                 }
 306  0
                 location++;
 307  0
             }
 308  
         }
 309  0
         if (!alreadyAdded) {
 310  0
             getResponsibilities().add(ruleResponsibility);
 311  
         }
 312  0
     }
 313  
 
 314  
     public RuleTemplate getRuleTemplate() {
 315  0
         return ruleTemplate;
 316  
     }
 317  
 
 318  
     public void setRuleTemplate(RuleTemplate ruleTemplate) {
 319  0
         this.ruleTemplate = ruleTemplate;
 320  0
     }
 321  
 
 322  
     public String getRuleTemplateId() {
 323  0
         return ruleTemplateId;
 324  
     }
 325  
 
 326  
     public void setRuleTemplateId(String ruleTemplateId) {
 327  0
         this.ruleTemplateId = ruleTemplateId;
 328  0
     }
 329  
 
 330  
     public DocumentType getDocumentType() {
 331  0
             return KEWServiceLocator.getDocumentTypeService().findByName(getDocTypeName());
 332  
     }
 333  
 
 334  
     public String getDocTypeName() {
 335  0
         return docTypeName;
 336  
     }
 337  
 
 338  
     public void setDocTypeName(String docTypeName) {
 339  0
         this.docTypeName = docTypeName;
 340  0
     }
 341  
 
 342  
     public List<RuleExtension> getRuleExtensions() {
 343  0
         return ruleExtensions;
 344  
     }
 345  
 
 346  
     public void setRuleExtensions(List<RuleExtension> ruleExtensions) {
 347  0
         this.ruleExtensions = ruleExtensions;
 348  0
     }
 349  
 
 350  
     public List<RuleResponsibility> getResponsibilities() {
 351  0
         return responsibilities;
 352  
     }
 353  
 
 354  
     public void setResponsibilities(List<RuleResponsibility> responsibilities) {
 355  0
         this.responsibilities = responsibilities;
 356  0
     }
 357  
 
 358  
     public RuleResponsibility getResponsibility(Long ruleResponsibilityKey) {
 359  0
         for (Iterator iterator = getResponsibilities().iterator(); iterator.hasNext();) {
 360  0
             RuleResponsibility responsibility = (RuleResponsibility) iterator.next();
 361  0
             if (responsibility.getRuleResponsibilityKey() != null
 362  
                     && responsibility.getRuleResponsibilityKey().equals(ruleResponsibilityKey)) {
 363  0
                 return responsibility;
 364  
             }
 365  0
         }
 366  0
         return null;
 367  
     }
 368  
 
 369  
     public void removeResponsibility(int index) {
 370  0
         getResponsibilities().remove(index);
 371  0
     }
 372  
 
 373  
     public Boolean getActiveInd() {
 374  0
         return activeInd;
 375  
     }
 376  
 
 377  
     public void setActiveInd(Boolean activeInd) {
 378  0
         this.activeInd = activeInd;
 379  0
     }
 380  
 
 381  
     public String getActiveIndDisplay() {
 382  0
         if (getActiveInd() == null) {
 383  0
             return KEWConstants.INACTIVE_LABEL_LOWER;
 384  
         }
 385  0
         return CodeTranslator.getActiveIndicatorLabel(getActiveInd());
 386  
     }
 387  
 
 388  
     public Boolean getCurrentInd() {
 389  0
         return currentInd;
 390  
     }
 391  
 
 392  
     public void setCurrentInd(Boolean currentInd) {
 393  0
         this.currentInd = currentInd;
 394  0
     }
 395  
 
 396  
     public Timestamp getFromDate() {
 397  0
         return fromDate;
 398  
     }
 399  
 
 400  
     public void setFromDate(Timestamp fromDate) {
 401  0
         this.fromDate = fromDate;
 402  0
     }
 403  
 
 404  
     public String getDescription() {
 405  0
         return description;
 406  
     }
 407  
 
 408  
     public void setDescription(String description) {
 409  0
         this.description = description;
 410  0
     }
 411  
 
 412  
     public String getRuleBaseValuesId() {
 413  0
         return ruleBaseValuesId;
 414  
     }
 415  
 
 416  
     public void setRuleBaseValuesId(String ruleBaseValuesId) {
 417  0
         this.ruleBaseValuesId = ruleBaseValuesId;
 418  0
     }
 419  
 
 420  
     public Timestamp getToDate() {
 421  0
         return toDate;
 422  
     }
 423  
 
 424  
     public void setToDate(Timestamp toDate) {
 425  0
         this.toDate = toDate;
 426  0
     }
 427  
 
 428  
     public Integer getVersionNbr() {
 429  0
         return versionNbr;
 430  
     }
 431  
 
 432  
     public void setVersionNbr(Integer versionNbr) {
 433  0
         this.versionNbr = versionNbr;
 434  0
     }
 435  
 
 436  
     public String getReturnUrl() {
 437  0
         return returnUrl;
 438  
     }
 439  
 
 440  
     public void setReturnUrl(String returnUrl) {
 441  0
         this.returnUrl = returnUrl;
 442  0
     }
 443  
 
 444  
     public String getFromDateString() {
 445  0
         if (this.fromDate != null) {
 446  0
             return RiceConstants.getDefaultDateFormat().format(this.fromDate);
 447  
         }
 448  0
         return null;
 449  
     }
 450  
 
 451  
     public String getToDateString() {
 452  0
         if (this.toDate != null) {
 453  0
             return RiceConstants.getDefaultDateFormat().format(this.toDate);
 454  
         }
 455  0
         return null;
 456  
     }
 457  
 
 458  
     public Boolean getForceAction() {
 459  0
         return forceAction;
 460  
     }
 461  
 
 462  
     public void setForceAction(Boolean forceAction) {
 463  0
         this.forceAction = forceAction;
 464  0
     }
 465  
 
 466  
     public boolean isActive(Date date) {
 467  0
             boolean isAfterFromDate = getFromDate() == null || date.after(getFromDate());
 468  0
             boolean isBeforeToDate = getToDate() == null || date.before(getToDate());
 469  0
             return getActiveInd() && isAfterFromDate && isBeforeToDate;
 470  
     }
 471  
 
 472  
     public boolean isMatch(DocumentContent docContent) {
 473  0
         for (Iterator iter = getRuleTemplate().getActiveRuleTemplateAttributes().iterator(); iter.hasNext();) {
 474  0
             RuleTemplateAttribute ruleTemplateAttribute = (RuleTemplateAttribute) iter.next();
 475  0
             if (!ruleTemplateAttribute.isWorkflowAttribute()) {
 476  0
                 continue;
 477  
             }
 478  0
             WorkflowAttribute routingAttribute = (WorkflowAttribute) ruleTemplateAttribute.getWorkflowAttribute();
 479  
 
 480  0
             RuleAttribute ruleAttribute = ruleTemplateAttribute.getRuleAttribute();
 481  0
             if (ruleAttribute.getType().equals(KEWConstants.RULE_XML_ATTRIBUTE_TYPE)) {
 482  0
                 ((GenericXMLRuleAttribute) routingAttribute).setRuleAttribute(ruleAttribute);
 483  
             }
 484  0
             String className = ruleAttribute.getClassName();
 485  0
             List<RuleExtension> editedRuleExtensions = new ArrayList<RuleExtension>();
 486  0
             for (Iterator iter2 = getRuleExtensions().iterator(); iter2.hasNext();) {
 487  0
                 RuleExtension extension = (RuleExtension) iter2.next();
 488  0
                 if (extension.getRuleTemplateAttribute().getRuleAttribute().getClassName().equals(className)) {
 489  0
                     editedRuleExtensions.add(extension);
 490  
                 }
 491  0
             }
 492  0
             if (!routingAttribute.isMatch(docContent, editedRuleExtensions)) {
 493  0
                 return false;
 494  
             }
 495  0
         }
 496  0
         return true;
 497  
     }
 498  
 
 499  
     public RuleResponsibility findResponsibility(String roleName) {
 500  0
         for (Iterator iter = getResponsibilities().iterator(); iter.hasNext();) {
 501  0
             RuleResponsibility resp = (RuleResponsibility) iter.next();
 502  0
             if (KEWConstants.RULE_RESPONSIBILITY_ROLE_ID.equals(resp.getRuleResponsibilityType())
 503  
                     && roleName.equals(resp.getRuleResponsibilityName())) {
 504  0
                 return resp;
 505  
             }
 506  0
         }
 507  0
         return null;
 508  
     }
 509  
 
 510  
     public String getDocumentId() {
 511  0
         return documentId;
 512  
     }
 513  
 
 514  
     public void setDocumentId(String documentId) {
 515  0
         this.documentId = documentId;
 516  0
     }
 517  
 
 518  
     public Boolean getDelegateRule() {
 519  0
         return delegateRule;
 520  
     }
 521  
 
 522  
     public void setDelegateRule(Boolean isDelegateRule) {
 523  0
         this.delegateRule = isDelegateRule;
 524  0
     }
 525  
 
 526  
     public Timestamp getActivationDate() {
 527  0
         return activationDate;
 528  
     }
 529  
 
 530  
     public void setActivationDate(Timestamp activationDate) {
 531  0
         this.activationDate = activationDate;
 532  0
     }
 533  
 
 534  
     public MyColumns getMyColumns() {
 535  0
         return myColumns;
 536  
     }
 537  
 
 538  
     public void setMyColumns(MyColumns additionalColumns) {
 539  0
         this.myColumns = additionalColumns;
 540  0
     }
 541  
 
 542  
     public String getDestinationUrl() {
 543  0
         return destinationUrl;
 544  
     }
 545  
 
 546  
     public void setDestinationUrl(String destinationUrl) {
 547  0
         this.destinationUrl = destinationUrl;
 548  0
     }
 549  
 
 550  
     public Timestamp getDeactivationDate() {
 551  0
         return deactivationDate;
 552  
     }
 553  
 
 554  
     public void setDeactivationDate(Timestamp deactivationDate) {
 555  0
         this.deactivationDate = deactivationDate;
 556  0
     }
 557  
 
 558  
     /**
 559  
      * @return whether this is a defaults/template rule
 560  
      */
 561  
     public Boolean getTemplateRuleInd() {
 562  0
         return templateRuleInd;
 563  
     }
 564  
 
 565  
     /**
 566  
      * @param templateRuleInd whether this is a defaults/template rule
 567  
      */
 568  
     public void setTemplateRuleInd(Boolean templateRuleInd) {
 569  0
         this.templateRuleInd = templateRuleInd;
 570  0
     }
 571  
 
 572  
     /**
 573  
      * Get the rule name
 574  
      * @return the rule name
 575  
      */
 576  
     public String getName() {
 577  0
         return name;
 578  
     }
 579  
 
 580  
     /**
 581  
      * Set the rule name
 582  
      * @param name the rule name
 583  
      */
 584  
     public void setName(String name) {
 585  0
         this.name = name;
 586  0
     }
 587  
 
 588  
         public List<PersonRuleResponsibility> getPersonResponsibilities() {
 589  0
                 return this.personResponsibilities;
 590  
         }
 591  
 
 592  
         public void setPersonResponsibilities(List<PersonRuleResponsibility> personResponsibilities) {
 593  0
                 this.personResponsibilities = personResponsibilities;
 594  0
         }
 595  
 
 596  
         public List<GroupRuleResponsibility> getGroupResponsibilities() {
 597  0
                 return this.groupResponsibilities;
 598  
         }
 599  
 
 600  
         public void setGroupResponsibilities(List<GroupRuleResponsibility> groupResponsibilities) {
 601  0
                 this.groupResponsibilities = groupResponsibilities;
 602  0
         }
 603  
 
 604  
         public List<RoleRuleResponsibility> getRoleResponsibilities() {
 605  0
                 return this.roleResponsibilities;
 606  
         }
 607  
 
 608  
         public void setRoleResponsibilities(List<RoleRuleResponsibility> roleResponsibilities) {
 609  0
                 this.roleResponsibilities = roleResponsibilities;
 610  0
         }
 611  
 
 612  
         /**
 613  
          * @return the fieldValues
 614  
          */
 615  
         public Map<String, String> getFieldValues() {
 616  0
                 return this.fieldValues;
 617  
         }
 618  
 
 619  
         /**
 620  
          * @param fieldValues the fieldValues to set
 621  
          */
 622  
         public void setFieldValues(Map<String, String> fieldValues) {
 623  0
                 this.fieldValues = fieldValues;
 624  0
         }
 625  
 
 626  
     public String getGroupReviewerName() {
 627  0
         return this.groupReviewerName;
 628  
     }
 629  
 
 630  
     public String getGroupReviewerNamespace() {
 631  0
         return this.groupReviewerNamespace;
 632  
     }
 633  
 
 634  
     public String getPersonReviewer() {
 635  0
         return this.personReviewer;
 636  
     }
 637  
 
 638  
     public void setGroupReviewerName(String groupReviewerName) {
 639  0
         this.groupReviewerName = groupReviewerName;
 640  0
     }
 641  
 
 642  
     public void setGroupReviewerNamespace(String groupReviewerNamespace) {
 643  0
         this.groupReviewerNamespace = groupReviewerNamespace;
 644  0
     }
 645  
 
 646  
     public void setPersonReviewer(String personReviewer) {
 647  0
         this.personReviewer = personReviewer;
 648  0
     }
 649  
 
 650  
     /*public Group getKimGroupImpl() {
 651  
         return new GroupImpl;
 652  
     }*/
 653  
 
 654  
     public PersonImpl getPersonImpl() {
 655  0
         return new PersonImpl();
 656  
     }
 657  
 
 658  
     public String getPersonReviewerType() {
 659  0
         return this.personReviewerType;
 660  
     }
 661  
 
 662  
     public void setPersonReviewerType(String personReviewerType) {
 663  0
         this.personReviewerType = personReviewerType;
 664  0
     }
 665  
 }