org.kuali.rice.kew.rule.bo
Class RuleTemplateBo

java.lang.Object
  extended by org.kuali.rice.krad.bo.BusinessObjectBase
      extended by org.kuali.rice.krad.bo.PersistableBusinessObjectBase
          extended by org.kuali.rice.kew.rule.bo.RuleTemplateBo
All Implemented Interfaces:
Serializable, org.apache.ojb.broker.PersistenceBrokerAware, GloballyUnique, Identifiable, Versioned, ModelObjectBasic, RuleTemplateContract, BusinessObject, PersistableBusinessObject

@Entity
public class RuleTemplateBo
extends PersistableBusinessObjectBase
implements RuleTemplateContract

A model bean which represents a template upon which a rule is created. The RuleTemplate is essentially a collection of RuleAttributes (associated vai the RuleTemplateAttributeBo bean).

Author:
Kuali Rice Team (rice.collab@kuali.org)
See Also:
Serialized Form

Field Summary
static String[] DEFAULT_OPTION_KEYS
          A list of default rule template option keys.
 
Fields inherited from class org.kuali.rice.krad.bo.PersistableBusinessObjectBase
extension, newCollectionRecord, objectId, versionNumber
 
Constructor Summary
RuleTemplateBo()
           
 
Method Summary
 boolean containsActiveRuleTemplateAttribute(RuleTemplateAttributeBo templateAttribute)
           
 boolean containsRuleTemplateAttribute(RuleTemplateAttributeBo templateAttribute)
           
 RuleTemplateOptionBo getAcknowledge()
           
 List<RuleTemplateAttributeBo> getActiveRuleTemplateAttributes()
          Returns a List of only the active RuleTemplateAttributes on the RuleTemplate sorted according to display order (ascending).
 RuleTemplateOptionBo getApprove()
           
 RuleTemplateOptionBo getComplete()
           
 RuleTemplateOptionBo getDefaultActionRequestValue()
           
 String getDelegateTemplateName()
           
 RuleTemplateBo getDelegationTemplate()
           
 String getDelegationTemplateId()
           
 String getDescription()
           
 String getEncodedName()
          Used from the rule quicklinks when doing the focus channel.
 RuleTemplateOptionBo getFyi()
           
 String getId()
          The unique identifier for an object.
 String getName()
           
 String getReturnUrl()
           
 List<RoleName> getRoles()
          Returns a List of Roles from all RoleAttributes attached to this template.
 String getRuleTemplateActionsUrl()
           
 RuleTemplateAttributeBo getRuleTemplateAttribute(int index)
           
 RuleTemplateAttributeBo getRuleTemplateAttribute(RuleTemplateAttributeBo ruleTemplateAttribute)
           
 List<RuleTemplateAttributeBo> getRuleTemplateAttributes()
           
 RuleTemplateOptionBo getRuleTemplateOption(String key)
           
 List<RuleTemplateOptionBo> getRuleTemplateOptions()
           
 void removeNonDefaultOptions()
          Removes any non-default rule template options on the template
 void setAcknowledge(RuleTemplateOptionBo acknowledge)
           
 void setActiveRuleTemplateAttributes(List<RuleTemplateAttributeBo> ruleTemplateAttributes)
          This is implemented to allow us to use this collection on the inquiry for RuleTemplate.
 void setApprove(RuleTemplateOptionBo approve)
           
 void setComplete(RuleTemplateOptionBo complete)
           
 void setDefaultActionRequestValue(RuleTemplateOptionBo defaultActionRequestValue)
           
 void setDelegationTemplate(RuleTemplateBo delegationTemplate)
           
 void setDelegationTemplateId(String delegationTemplateId)
           
 void setDescription(String description)
           
 void setFyi(RuleTemplateOptionBo fyi)
           
 void setId(String id)
           
 void setName(String name)
           
 void setReturnUrl(String returnUrl)
           
 void setRuleTemplateAttributes(List<RuleTemplateAttributeBo> ruleTemplateAttributes)
           
 void setRuleTemplateOptions(List<RuleTemplateOptionBo> ruleTemplateOptions)
           
static RuleTemplate to(RuleTemplateBo bo)
           
 
Methods inherited from class org.kuali.rice.krad.bo.PersistableBusinessObjectBase
afterDelete, afterInsert, afterLookup, afterUpdate, beforeDelete, beforeInsert, beforeUpdate, buildListOfDeletionAwareLists, getExtension, getLegacyDataAdapter, getObjectId, getVersionNumber, isNewCollectionRecord, linkEditableUserFields, postLoad, postPersist, postRemove, postUpdate, prePersist, preRemove, preUpdate, refresh, refreshNonUpdateableReferences, refreshReferenceObject, setExtension, setNewCollectionRecord, setObjectId, setVersionNumber
 
Methods inherited from class org.kuali.rice.krad.bo.BusinessObjectBase
toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.kuali.rice.core.api.mo.common.Versioned
getVersionNumber
 
Methods inherited from interface org.kuali.rice.core.api.mo.common.GloballyUnique
getObjectId
 
Methods inherited from interface org.kuali.rice.core.api.mo.ModelObjectBasic
toString
 

Field Detail

DEFAULT_OPTION_KEYS

public static final String[] DEFAULT_OPTION_KEYS
A list of default rule template option keys.

Constructor Detail

RuleTemplateBo

public RuleTemplateBo()
Method Detail

removeNonDefaultOptions

public void removeNonDefaultOptions()
Removes any non-default rule template options on the template


getDelegateTemplateName

public String getDelegateTemplateName()

getRuleTemplateActionsUrl

public String getRuleTemplateActionsUrl()

getRuleTemplateAttribute

public RuleTemplateAttributeBo getRuleTemplateAttribute(RuleTemplateAttributeBo ruleTemplateAttribute)

containsActiveRuleTemplateAttribute

public boolean containsActiveRuleTemplateAttribute(RuleTemplateAttributeBo templateAttribute)

containsRuleTemplateAttribute

public boolean containsRuleTemplateAttribute(RuleTemplateAttributeBo templateAttribute)

getRuleTemplateAttribute

public RuleTemplateAttributeBo getRuleTemplateAttribute(int index)

getRuleTemplateAttributes

public List<RuleTemplateAttributeBo> getRuleTemplateAttributes()
Specified by:
getRuleTemplateAttributes in interface RuleTemplateContract

getActiveRuleTemplateAttributes

public List<RuleTemplateAttributeBo> getActiveRuleTemplateAttributes()
Returns a List of only the active RuleTemplateAttributes on the RuleTemplate sorted according to display order (ascending).

Returns:

setActiveRuleTemplateAttributes

public void setActiveRuleTemplateAttributes(List<RuleTemplateAttributeBo> ruleTemplateAttributes)
This is implemented to allow us to use this collection on the inquiry for RuleTemplate. In the KNS code it does an explicit check that the property is writable.


setRuleTemplateAttributes

public void setRuleTemplateAttributes(List<RuleTemplateAttributeBo> ruleTemplateAttributes)

getDescription

public String getDescription()
Specified by:
getDescription in interface RuleTemplateContract

setDescription

public void setDescription(String description)

getName

public String getName()
Specified by:
getName in interface RuleTemplateContract

setName

public void setName(String name)

getId

public String getId()
Description copied from interface: Identifiable
The unique identifier for an object. This can be null.

Specified by:
getId in interface Identifiable
Returns:
the id

setId

public void setId(String id)

getDelegationTemplateId

public String getDelegationTemplateId()

setDelegationTemplateId

public void setDelegationTemplateId(String delegationTemplateId)

getDelegationTemplate

public RuleTemplateBo getDelegationTemplate()
Specified by:
getDelegationTemplate in interface RuleTemplateContract

setDelegationTemplate

public void setDelegationTemplate(RuleTemplateBo delegationTemplate)

getReturnUrl

public String getReturnUrl()

setReturnUrl

public void setReturnUrl(String returnUrl)

getEncodedName

public String getEncodedName()
Used from the rule quicklinks when doing the focus channel.


getRuleTemplateOptions

public List<RuleTemplateOptionBo> getRuleTemplateOptions()
Specified by:
getRuleTemplateOptions in interface RuleTemplateContract

setRuleTemplateOptions

public void setRuleTemplateOptions(List<RuleTemplateOptionBo> ruleTemplateOptions)

getRuleTemplateOption

public RuleTemplateOptionBo getRuleTemplateOption(String key)

setAcknowledge

public void setAcknowledge(RuleTemplateOptionBo acknowledge)

setComplete

public void setComplete(RuleTemplateOptionBo complete)

setApprove

public void setApprove(RuleTemplateOptionBo approve)

setFyi

public void setFyi(RuleTemplateOptionBo fyi)

setDefaultActionRequestValue

public void setDefaultActionRequestValue(RuleTemplateOptionBo defaultActionRequestValue)

getAcknowledge

public RuleTemplateOptionBo getAcknowledge()

getComplete

public RuleTemplateOptionBo getComplete()

getApprove

public RuleTemplateOptionBo getApprove()

getFyi

public RuleTemplateOptionBo getFyi()

getDefaultActionRequestValue

public RuleTemplateOptionBo getDefaultActionRequestValue()

getRoles

public List<RoleName> getRoles()
Returns a List of Roles from all RoleAttributes attached to this template.

Returns:
list of roles

to

public static RuleTemplate to(RuleTemplateBo bo)


Copyright © 2005–2014 The Kuali Foundation. All rights reserved.