Examination
Section contains description of Process "
Examination.process
" .
Folder description:
Folder |
Description |
|
No description |
Process definition:
Full process path:
ProcessDefinitions/Examination/Examination.process
Process starter activity:
Name:
Start
Description:
Input Parameters:
-
+
InputParameters
(Complex Type,
required
)
-
-
Refund(xsd:long,required)
-
-
Salary(xsd:long,required)
-
-
Value(xsd:long,required)
-
-
Bonita(xsd:short,required)
-
-
Pawn(xsd:boolean,required)
Process end activity:
Name:
End
Output Parameters:
-
+
ExaminationResult
(Complex Type,
required
)
-
-
State(xsd:boolean,required)
-
-
Interest(xsd:double,required)
Return bindings:
Mapping table
Target |
Source |
/ExaminationResult/State |
if(($GetMinRefund-JavaCode/javaCodeActivityOutput/MinRefund <= $Start/InputParameters/Refund) and ($Schema0/Interest > 0))then 1 else 0 |
/ExaminationResult/Interest |
$Schema0/Interest |
Mapping tree
Mapping |
ExaminationResult
State = if(($GetMinRefund-JavaCode/javaCodeActivityOutput/MinRefund <= $Start/InputParameters/Refund) and ($Schema0/Interest > 0))then 1 else 0
Interest = $Schema0/Interest
|
Source code
Mapping |
<ExaminationResult xmlns:pd="http://xmlns.tibco.com/bw/process/2003" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<State>
<xsl:value-of select="if(($GetMinRefund-JavaCode/javaCodeActivityOutput/MinRefund <= $Start/InputParameters/Refund) and ($Schema0/Interest > 0))then 1 else 0"/>
</State>
<Interest>
<xsl:value-of select="$Schema0/Interest"/>
</Interest>
</ExaminationResult>
|
Process variables:
Schema:
Schema0
-
-
Interest(xsd:double,required)
Activities:
Name:
GetMinRefund JavaCode
-
Type:
com.tibco.plugin.java.JavaActivity
-
Resource Type:
ae.javapalette.javaActivity
-
Description:
- Configuration:
- fileName
=
ExaminationGetMinRefundJavaCode
- packageName
=
ProcessDefinitions.Examination.Examination
- fullsource
=
package ProcessDefinitions.Examination.Examination;
import java.util.*;
import java.io.*;
import java.lang.Math;
public class ExaminationGetMinRefundJavaCode{
/****** START SET/GET METHOD, DO NOT MODIFY *****/
protected long Years = 0;
protected double Interest = 0.0d;
protected long Value = 0;
protected long MinRefund = 0;
public long getYears() {
return Years;
}
public void setYears(long val) {
Years = val;
}
public double getInterest() {
return Interest;
}
public void setInterest(double val) {
Interest = val;
}
public long getValue() {
return Value;
}
public void setValue(long val) {
Value = val;
}
public long getMinRefund() {
return MinRefund;
}
public void setMinRefund(long val) {
MinRefund = val;
}
/****** END SET/GET METHOD, DO NOT MODIFY *****/
private double power(double x, long y)
{
double result = x;
for(long i = 0; i < y-1; i++)
{
result = result * x;
}
return result;
}
public ExaminationGetMinRefundJavaCode() {
double temp = power((1 + 0.10/12),(getYears()*12));
setMinRefund((long)Math.round((getValue() * getInterest() /12 *temp) / (temp-1)));
}
public void invoke() throws Exception {
/* Available Variables: DO NOT MODIFY
In : long Years
In : double Interest
In : long Value
Out : long MinRefund
* Available Variables: DO NOT MODIFY *****/
}
}
- inputData
- row
- fieldName
=
Years
- fieldType
=
long
- fieldRequired
=
required
- row
- fieldName
=
Interest
- fieldType
=
double
- fieldRequired
=
required
- row
- fieldName
=
Value
- fieldType
=
long
- fieldRequired
=
required
- outputData
- row
- fieldName
=
MinRefund
- fieldType
=
long
- fieldRequired
=
required
- byteCode
- class
- name
=
ExaminationGetMinRefundJavaCode
- byteCode
(Java bytecode is ignored in this documentation)
- Input bindings:
Mapping table
Target |
Source |
/javaCodeActivityInput/Years |
20 |
/javaCodeActivityInput/Interest |
$Schema0/Interest * 0.01 |
/javaCodeActivityInput/Value |
$Start/InputParameters/Value |
Mapping tree
Mapping |
javaCodeActivityInput
Years = 20
Interest = $Schema0/Interest * 0.01
Value = $Start/InputParameters/Value
|
Source code
Mapping |
<javaCodeActivityInput xmlns:pd="http://xmlns.tibco.com/bw/process/2003" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<Years>
<xsl:value-of select="20"/>
</Years>
<Interest>
<xsl:value-of select="$Schema0/Interest * 0.01"/>
</Interest>
<Value>
<xsl:value-of select="$Start/InputParameters/Value"/>
</Value>
</javaCodeActivityInput>
|
Name:
Interest Assign
-
Type:
com.tibco.pe.core.AssignActivity
-
Resource Type:
ae.activities.assignActivity
-
Description:
- Configuration:
- Input bindings:
Mapping table
Target |
Source |
/Interest |
if($Start/InputParameters/Bonita >= 4) then 3 else
if($Start/InputParameters/Bonita >= 3) then 3.5 else
if($Start/InputParameters/Bonita >= 2) then 4 else
if($Start/InputParameters/Bonita >= 1) then 4.5 else 0 |
Mapping tree
Mapping |
Interest = if($Start/InputParameters/Bonita >= 4) then 3 else
if($Start/InputParameters/Bonita >= 3) then 3.5 else
if($Start/InputParameters/Bonita >= 2) then 4 else
if($Start/InputParameters/Bonita >= 1) then 4.5 else 0
|
Source code
Mapping |
<Interest xmlns:pd="http://xmlns.tibco.com/bw/process/2003" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<xsl:value-of select="if($Start/InputParameters/Bonita >= 4) then 3 else
if($Start/InputParameters/Bonita >= 3) then 3.5 else
if($Start/InputParameters/Bonita >= 2) then 4 else
if($Start/InputParameters/Bonita >= 1) then 4.5 else 0"/>
</Interest>
|
Transitions:
-
From:
GetMinRefund JavaCode
-To:
End
-
Label:
-
Condition:
Success
-
Description:
-
From:
Interest Assign
-To:
GetMinRefund JavaCode
-
Label:
-
Condition:
Success
-
Description:
-
From:
Start
-To:
Interest Assign
-
Label:
-
Condition:
Success
-
Description: