Class NaturalLanguageTemplate.Builder
java.lang.Object
org.kuali.rice.krms.api.repository.language.NaturalLanguageTemplate.Builder
- All Implemented Interfaces:
Serializable,org.kuali.rice.core.api.mo.common.active.Inactivatable,org.kuali.rice.core.api.mo.common.Identifiable,org.kuali.rice.core.api.mo.common.Versioned,org.kuali.rice.core.api.mo.ModelBuilder,NaturalLanguageTemplateContract
- Enclosing class:
NaturalLanguageTemplate
public static final class NaturalLanguageTemplate.Builder
extends Object
implements Serializable, org.kuali.rice.core.api.mo.ModelBuilder, NaturalLanguageTemplateContract
A builder which can be used to construct
NaturalLanguageTemplate instances. Enforces the constraints of the NaturalLanguageTemplateContract.- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds an instance of a NaturalLanguageTemplate based on the current state of the builder.create(NaturalLanguageTemplateContract contract) This method returns a list of custom/remote attributes associated with the agenda.getId()This is the Language Code of the NaturalLanguageTemplateThis is the NaturalLanguageUsageId of the NaturalLanguageTemplateThis is the Template of the NaturalLanguageTemplateThis is the TypeId of the NaturalLanguageTemplatebooleanisActive()voidsetActive(boolean active) Sets the value of active on this builder to the given value.voidsetAttributes(Map<String, String> attributes) Sets the Map of attributes as name / value pairs.voidSets the value of id on this builder to the given value.voidsetLanguageCode(String languageCode) Sets the value of languageCode on this builder to the given value.voidsetNaturalLanguageUsageId(String naturalLanguageUsageId) Sets the value of naturalLanguageUsageId on this builder to the given value.voidsetTemplate(String template) Sets the value of template on this builder to the given value.voidSets the value of typeId on this builder to the given value.voidsetVersionNumber(Long versionNumber) Sets the value of versionNumber on this builder to the given value.
-
Method Details
-
create
public static NaturalLanguageTemplate.Builder create(String languageCode, String naturalLanguageUsageId, String template, String typeId) -
create
-
build
Builds an instance of a NaturalLanguageTemplate based on the current state of the builder.- Specified by:
buildin interfaceorg.kuali.rice.core.api.mo.ModelBuilder- Returns:
- the fully-constructed NaturalLanguageTemplate.
-
isActive
public boolean isActive()- Specified by:
isActivein interfaceorg.kuali.rice.core.api.mo.common.active.Inactivatable
-
getAttributes
Description copied from interface:NaturalLanguageTemplateContractThis method returns a list of custom/remote attributes associated with the agenda.The attributes of the NaturalLanguageUsage
- Specified by:
getAttributesin interfaceNaturalLanguageTemplateContract- Returns:
- a list of custom/remote attribute of the agenda.
-
getId
- Specified by:
getIdin interfaceorg.kuali.rice.core.api.mo.common.Identifiable
-
getLanguageCode
Description copied from interface:NaturalLanguageTemplateContractThis is the Language Code of the NaturalLanguageTemplateThe Language Code of the NaturalLanguageTemplate
- Specified by:
getLanguageCodein interfaceNaturalLanguageTemplateContract- Returns:
- the Language Code of the NaturalLanguageTemplate
-
getNaturalLanguageUsageId
Description copied from interface:NaturalLanguageTemplateContractThis is the NaturalLanguageUsageId of the NaturalLanguageTemplateThe NaturalLanguageUsageId of the NaturalLanguageTemplate
- Specified by:
getNaturalLanguageUsageIdin interfaceNaturalLanguageTemplateContract- Returns:
- the NaturalLanguageUsageId of the NaturalLanguageTemplate
-
getTemplate
Description copied from interface:NaturalLanguageTemplateContractThis is the Template of the NaturalLanguageTemplateThe Template of the NaturalLanguageTemplate
- Specified by:
getTemplatein interfaceNaturalLanguageTemplateContract- Returns:
- the Template of the NaturalLanguageTemplate
-
getTypeId
Description copied from interface:NaturalLanguageTemplateContractThis is the TypeId of the NaturalLanguageTemplateThe TypeId of the NaturalLanguageTemplate
- Specified by:
getTypeIdin interfaceNaturalLanguageTemplateContract- Returns:
- the TypeId of the NaturalLanguageTemplate
-
getVersionNumber
- Specified by:
getVersionNumberin interfaceorg.kuali.rice.core.api.mo.common.Versioned
-
setActive
public void setActive(boolean active) Sets the value of active on this builder to the given value.- Parameters:
active- the active value to set.
-
setAttributes
Sets the Map of attributes as name / value pairs.- Parameters:
attributes- a Map of name value String pairs representing the attributes.
-
setId
Sets the value of id on this builder to the given value.- Parameters:
id- the id value to set., may be null, representing the Object has not been persisted, but must not be blank.- Throws:
IllegalArgumentException- if the id is blank
-
setLanguageCode
Sets the value of languageCode on this builder to the given value.- Parameters:
languageCode- the languageCode value to set., must not be null or blank- Throws:
IllegalArgumentException- if the languageCode is null or blank
-
setNaturalLanguageUsageId
Sets the value of naturalLanguageUsageId on this builder to the given value.- Parameters:
naturalLanguageUsageId- the naturalLanguageUsageId value to set., must not be null or blank- Throws:
IllegalArgumentException- if the naturalLanguageUsageId is null or blank
-
setTemplate
Sets the value of template on this builder to the given value.- Parameters:
template- the template value to set., must not be null or blank- Throws:
IllegalArgumentException- if the template is null or blank
-
setTypeId
Sets the value of typeId on this builder to the given value.- Parameters:
typeId- the typeId value to set., must not be null or blank- Throws:
IllegalArgumentException- if the typeId is null or blank
-
setVersionNumber
Sets the value of versionNumber on this builder to the given value.- Parameters:
versionNumber- the versionNumber value to set.
-