public abstract class ProtocolAttachmentBaseRuleHelper extends Object
ProtocolAttachmentBase.| Modifier | Constructor and Description |
|---|---|
protected |
ProtocolAttachmentBaseRuleHelper(ProtocolAttachmentService attachmentService,
org.kuali.rice.kns.service.DictionaryValidationService validationService)
Creates helper deferring the setting of the prefix to later and setting used services.
|
protected |
ProtocolAttachmentBaseRuleHelper(String aPropertyPrefix,
ProtocolAttachmentService attachmentService,
org.kuali.rice.kns.service.DictionaryValidationService validationService) |
| Modifier and Type | Method and Description |
|---|---|
void |
resetPropertyPrefix(String aPropertyPrefix)
Resets the property prefix.
|
<T extends ProtocolAttachmentBase & TypedAttachment> |
validDescriptionWhenRequired(T attachment)
Checks for a valid description when description is required.
|
boolean |
validPrimitiveFields(ProtocolAttachmentBase attachmentBase)
Validates the attachment's primitive fields (non reference fields).
|
<T extends ProtocolAttachmentBase & TypedAttachment> |
validTypeForGroup(T attachment)
Checks for a valid type for a group.
|
protected ProtocolAttachmentBaseRuleHelper(ProtocolAttachmentService attachmentService, org.kuali.rice.kns.service.DictionaryValidationService validationService)
attachmentService - the Attachment ServiceIllegalArgumentException - if the attachmentService is nullprotected ProtocolAttachmentBaseRuleHelper(String aPropertyPrefix, ProtocolAttachmentService attachmentService, org.kuali.rice.kns.service.DictionaryValidationService validationService)
public void resetPropertyPrefix(String aPropertyPrefix)
aPropertyPrefix - the prefix (ex: notesAttachmentsHelper.newAttachmentProtocol)IllegalArgumentException - if the propertyPrefix is nullpublic <T extends ProtocolAttachmentBase & TypedAttachment> boolean validDescriptionWhenRequired(T attachment)
T - the attachment "type"attachment - the attachment.public <T extends ProtocolAttachmentBase & TypedAttachment> boolean validTypeForGroup(T attachment)
This method does not validate the existence of a type code.
This validation is done by validType(ProtocolAttachmentBase).
If the type code is blank this method will return true.
T - the attachment "type"attachment - the attachment.public boolean validPrimitiveFields(ProtocolAttachmentBase attachmentBase)
attachmentBase - the attachmentCopyright © 2013 The Kuali Foundation. All Rights Reserved.