|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.kuali.rice.krms.api.repository.proposition.PropositionDefinition.Builder
public static class PropositionDefinition.Builder
This builder is used to construct instances of KRMS Proposition. It enforces the constraints of the PropositionDefinitionContract
.
Method Summary | |
---|---|
PropositionDefinition |
build()
Builds an instance of a Proposition based on the current state of the builder. |
PropositionDefinition.Builder |
compoundComponents(List<PropositionDefinition.Builder> components)
|
PropositionDefinition.Builder |
compoundOpCode(String opCode)
|
static PropositionDefinition.Builder |
create(PropositionDefinitionContract contract)
Creates a builder by populating it with data from the given PropositionDefinitionContract . |
static PropositionDefinition.Builder |
create(String propId,
String propTypeCode,
String ruleId,
String typeId,
List<PropositionParameter.Builder> parameters)
|
List<PropositionDefinition.Builder> |
getCompoundComponents()
This method returns the propositions which are contained in a compound proposition. |
String |
getCompoundOpCode()
This method returns the op code to be used when evaluating compound propositions. |
String |
getDescription()
This is the description text for the KRMS proposition |
String |
getId()
The unique identifier for an object. |
List<PropositionParameter.Builder> |
getParameters()
This is the parameter list of the proposition. |
String |
getPropositionTypeCode()
There are three main types of Propositions: Compound Propositions - a proposition consisting of other propositions and a boolean algebra operator (AND, OR) defining how to evaluate those propositions. |
String |
getRuleId()
This returns the ID of the rule this proposition belongs to. |
String |
getTypeId()
This is the id of Proposition KrmsType of the proposition. |
Long |
getVersionNumber()
Returns the version number for this object. |
void |
setCompoundComponents(List<PropositionDefinition.Builder> components)
|
void |
setCompoundOpCode(String opCode)
|
void |
setDescription(String desc)
|
void |
setId(String propId)
Sets the value of the id on this builder to the given value. |
void |
setParameters(List<PropositionParameter.Builder> parameters)
|
void |
setPropositionTypeCode(String propTypeCode)
|
void |
setRule(RuleDefinition.Builder rule)
|
void |
setRuleId(String ruleId)
|
void |
setTypeId(String typeId)
|
void |
setVersionNumber(Long versionNumber)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public PropositionDefinition.Builder compoundOpCode(String opCode)
public PropositionDefinition.Builder compoundComponents(List<PropositionDefinition.Builder> components)
public static PropositionDefinition.Builder create(String propId, String propTypeCode, String ruleId, String typeId, List<PropositionParameter.Builder> parameters)
public static PropositionDefinition.Builder create(PropositionDefinitionContract contract)
PropositionDefinitionContract
.
contract
- the contract from which to populate this builder
public void setId(String propId)
id
- the id value to setpublic void setDescription(String desc)
public void setTypeId(String typeId)
public void setRuleId(String ruleId)
public void setRule(RuleDefinition.Builder rule)
public void setPropositionTypeCode(String propTypeCode)
public void setParameters(List<PropositionParameter.Builder> parameters)
public void setCompoundOpCode(String opCode)
public void setCompoundComponents(List<PropositionDefinition.Builder> components)
public void setVersionNumber(Long versionNumber)
public String getId()
Identifiable
getId
in interface Identifiable
public String getDescription()
PropositionDefinitionContract
getDescription
in interface PropositionDefinitionContract
public String getRuleId()
PropositionDefinitionContract
getRuleId
in interface PropositionDefinitionContract
public String getTypeId()
PropositionDefinitionContract
getTypeId
in interface PropositionDefinitionContract
public String getPropositionTypeCode()
PropositionDefinitionContract
There are three main types of Propositions: Compound Propositions - a proposition consisting of other propositions and a boolean algebra operator (AND, OR) defining how to evaluate those propositions. Parameterized Propositions - a proposition which is parameterized by some set of values, evaluation logic is implemented by hand and returns true or false Simple Propositions - a proposition of the form lhs op rhs where lhs=left-hand side, rhs=right-hand side, and op=operator
getPropositionTypeCode
in interface PropositionDefinitionContract
Valid values are C = compound, P = parameterized, S = simple
public List<PropositionParameter.Builder> getParameters()
PropositionDefinitionContract
Compound Propositions will have an empty parameter list.
getParameters
in interface PropositionDefinitionContract
PropositionParameter
public String getCompoundOpCode()
PropositionDefinitionContract
getCompoundOpCode
in interface PropositionDefinitionContract
public List<PropositionDefinition.Builder> getCompoundComponents()
PropositionDefinitionContract
getCompoundComponents
in interface PropositionDefinitionContract
public Long getVersionNumber()
Versioned
getVersionNumber
in interface Versioned
public PropositionDefinition build()
build
in interface ModelBuilder
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |