Skip to content

Commit b1deafd

Browse files
committed
Initial source
1 parent acff2b9 commit b1deafd

12 files changed

+295
-0
lines changed
Lines changed: 118 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,118 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<projectDescription>
3+
<name>TreeTransformApplication</name>
4+
<comment></comment>
5+
<projects>
6+
</projects>
7+
<buildSpec>
8+
<buildCommand>
9+
<name>com.ibm.etools.mft.applib.applibbuilder</name>
10+
<arguments>
11+
</arguments>
12+
</buildCommand>
13+
<buildCommand>
14+
<name>com.ibm.etools.mft.applib.applibresourcevalidator</name>
15+
<arguments>
16+
</arguments>
17+
</buildCommand>
18+
<buildCommand>
19+
<name>com.ibm.etools.mft.connector.policy.ui.PolicyBuilder</name>
20+
<arguments>
21+
</arguments>
22+
</buildCommand>
23+
<buildCommand>
24+
<name>com.ibm.etools.mft.applib.mbprojectbuilder</name>
25+
<arguments>
26+
</arguments>
27+
</buildCommand>
28+
<buildCommand>
29+
<name>com.ibm.etools.msg.validation.dfdl.mlibdfdlbuilder</name>
30+
<arguments>
31+
</arguments>
32+
</buildCommand>
33+
<buildCommand>
34+
<name>com.ibm.etools.mft.flow.adapters.adapterbuilder</name>
35+
<arguments>
36+
</arguments>
37+
</buildCommand>
38+
<buildCommand>
39+
<name>com.ibm.etools.mft.flow.sca.scabuilder</name>
40+
<arguments>
41+
</arguments>
42+
</buildCommand>
43+
<buildCommand>
44+
<name>com.ibm.etools.msg.validation.dfdl.mbprojectresourcesbuilder</name>
45+
<arguments>
46+
</arguments>
47+
</buildCommand>
48+
<buildCommand>
49+
<name>com.ibm.etools.mft.esql.lang.esqllangbuilder</name>
50+
<arguments>
51+
</arguments>
52+
</buildCommand>
53+
<buildCommand>
54+
<name>com.ibm.etools.mft.map.builder.mslmappingbuilder</name>
55+
<arguments>
56+
</arguments>
57+
</buildCommand>
58+
<buildCommand>
59+
<name>com.ibm.etools.mft.flow.msgflowxsltbuilder</name>
60+
<arguments>
61+
</arguments>
62+
</buildCommand>
63+
<buildCommand>
64+
<name>com.ibm.etools.mft.flow.msgflowbuilder</name>
65+
<arguments>
66+
</arguments>
67+
</buildCommand>
68+
<buildCommand>
69+
<name>com.ibm.etools.mft.decision.service.ui.decisionservicerulebuilder</name>
70+
<arguments>
71+
</arguments>
72+
</buildCommand>
73+
<buildCommand>
74+
<name>com.ibm.etools.mft.pattern.capture.PatternBuilder</name>
75+
<arguments>
76+
</arguments>
77+
</buildCommand>
78+
<buildCommand>
79+
<name>com.ibm.etools.mft.json.builder.JSONBuilder</name>
80+
<arguments>
81+
</arguments>
82+
</buildCommand>
83+
<buildCommand>
84+
<name>com.ibm.etools.mft.restapi.ui.restApiDefinitionsBuilder</name>
85+
<arguments>
86+
</arguments>
87+
</buildCommand>
88+
<buildCommand>
89+
<name>com.ibm.etools.mft.policy.ui.policybuilder</name>
90+
<arguments>
91+
</arguments>
92+
</buildCommand>
93+
<buildCommand>
94+
<name>com.ibm.etools.mft.msg.assembly.messageAssemblyBuilder</name>
95+
<arguments>
96+
</arguments>
97+
</buildCommand>
98+
<buildCommand>
99+
<name>com.ibm.etools.msg.validation.dfdl.dfdlqnamevalidator</name>
100+
<arguments>
101+
</arguments>
102+
</buildCommand>
103+
<buildCommand>
104+
<name>com.ibm.etools.mft.bar.ext.barbuilder</name>
105+
<arguments>
106+
</arguments>
107+
</buildCommand>
108+
<buildCommand>
109+
<name>com.ibm.etools.mft.unittest.ui.TestCaseBuilder</name>
110+
<arguments>
111+
</arguments>
112+
</buildCommand>
113+
</buildSpec>
114+
<natures>
115+
<nature>com.ibm.etools.msgbroker.tooling.applicationNature</nature>
116+
<nature>com.ibm.etools.msgbroker.tooling.messageBrokerProjectNature</nature>
117+
</natures>
118+
</projectDescription>
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
{
2+
"$schema": "http://json-schema.org/draft-04/schema#",
3+
"title": "Issue",
4+
"type": "object",
5+
"properties": {
6+
"Problem": {
7+
"type": "object",
8+
"properties": {
9+
"Description": {
10+
"type": "string"
11+
}
12+
}
13+
}
14+
},
15+
"required": ["Problem"]
16+
}
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
3+
<xsd:element name="Problem">
4+
<xsd:complexType>
5+
<xsd:sequence>
6+
<xsd:element name="Description" type="xsd:string"/>
7+
</xsd:sequence>
8+
</xsd:complexType>
9+
</xsd:element>
10+
</xsd:schema>
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<ecore:EPackage xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:ComIbmTrace.msgnode="ComIbmTrace.msgnode" xmlns:ComIbmTreeTransform.msgnode="ComIbmTreeTransform.msgnode" xmlns:ComIbmWSInput.msgnode="ComIbmWSInput.msgnode" xmlns:ComIbmWSReply.msgnode="ComIbmWSReply.msgnode" xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" xmlns:eflow="http://www.ibm.com/wbi/2005/eflow" xmlns:utility="http://www.ibm.com/wbi/2005/eflow_utility" nsURI="TreeTransform.msgflow" nsPrefix="TreeTransform.msgflow">
3+
<eClassifiers xmi:type="eflow:FCMComposite" name="FCMComposite_1" nodeLayoutStyle="RECTANGLE">
4+
<eSuperTypes href="http://www.ibm.com/wbi/2005/eflow#//FCMBlock"/>
5+
<translation xmi:type="utility:TranslatableString" key="TreeTransform" bundleName="TreeTransform" pluginId="TreeTransformApplication"/>
6+
<colorGraphic16 xmi:type="utility:GIFFileGraphic" resourceName="platform:/plugin/TreeTransformApplication/icons/full/obj16/TreeTransform.gif"/>
7+
<colorGraphic32 xmi:type="utility:GIFFileGraphic" resourceName="platform:/plugin/TreeTransformApplication/icons/full/obj30/TreeTransform.gif"/>
8+
<composition>
9+
<nodes xmi:type="ComIbmWSInput.msgnode:FCMComposite_1" xmi:id="FCMComposite_1_1" location="16,50" URLSpecifier="/TreeTransform" messageDomainProperty="XMLNSC" validateTiming="immediate" validateMaster="contentAndValue">
10+
<translation xmi:type="utility:ConstantString" string="HTTP /TreeTransform"/>
11+
</nodes>
12+
<nodes xmi:type="ComIbmWSReply.msgnode:FCMComposite_1" xmi:id="FCMComposite_1_3" location="636,48">
13+
<translation xmi:type="utility:ConstantString" string="HTTP Reply"/>
14+
</nodes>
15+
<nodes xmi:type="ComIbmTreeTransform.msgnode:FCMComposite_1" xmi:id="FCMComposite_1_4" location="206,45" inputMessageDomainProperty="XMLNSC" messageDomainProperty="JSON" messageSetProperty="ModelJSON.json" outputMessageLocation="Context">
16+
<translation xmi:type="utility:ConstantString" string="TreeTransform"/>
17+
</nodes>
18+
<nodes xmi:type="ComIbmTrace.msgnode:FCMComposite_1" xmi:id="FCMComposite_1_5" location="407,48" destination="file" filePath="C:\temp\TreeTransform\Trace.txt" pattern="==================================================&#xD;&#xA;== The traditional Logical Tree structure is as follows ...&#xD;&#xA;==================================================&#xD;&#xA;${Root}&#xD;&#xA;==================================================&#xD;&#xA;== The Context Tree new with v13 is as follows ...&#xD;&#xA;==================================================&#xD;&#xA;${Context}">
19+
<translation xmi:type="utility:ConstantString" string="Trace"/>
20+
</nodes>
21+
<connections xmi:type="eflow:FCMConnection" xmi:id="FCMConnection_4" targetNode="FCMComposite_1_4" sourceNode="FCMComposite_1_1" sourceTerminalName="OutTerminal.out" targetTerminalName="InTerminal.in"/>
22+
<connections xmi:type="eflow:FCMConnection" xmi:id="FCMConnection_6" targetNode="FCMComposite_1_5" sourceNode="FCMComposite_1_4" sourceTerminalName="OutTerminal.out" targetTerminalName="InTerminal.in"/>
23+
<connections xmi:type="eflow:FCMConnection" xmi:id="FCMConnection_1" targetNode="FCMComposite_1_3" sourceNode="FCMComposite_1_5" sourceTerminalName="OutTerminal.out" targetTerminalName="InTerminal.in"/>
24+
</composition>
25+
<propertyOrganizer/>
26+
<stickyBoard/>
27+
</eClassifiers>
28+
</ecore:EPackage>
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<ecore:EPackage xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:ComIbmCompute.msgnode="ComIbmCompute.msgnode" xmlns:ComIbmWSInput.msgnode="ComIbmWSInput.msgnode" xmlns:ComIbmWSReply.msgnode="ComIbmWSReply.msgnode" xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" xmlns:eflow="http://www.ibm.com/wbi/2005/eflow" xmlns:utility="http://www.ibm.com/wbi/2005/eflow_utility" nsURI="TreeTransformValidateJSON.msgflow" nsPrefix="TreeTransformValidateJSON.msgflow">
3+
<eClassifiers xmi:type="eflow:FCMComposite" name="FCMComposite_1" nodeLayoutStyle="RECTANGLE">
4+
<eSuperTypes href="http://www.ibm.com/wbi/2005/eflow#//FCMBlock"/>
5+
<translation xmi:type="utility:TranslatableString" key="TreeTransformValidateJSON" bundleName="TreeTransformValidateJSON" pluginId="TreeTransformerApplication"/>
6+
<colorGraphic16 xmi:type="utility:GIFFileGraphic" resourceName="platform:/plugin/TreeTransformerApplication/icons/full/obj16/TreeTransformValidateJSON.gif"/>
7+
<colorGraphic32 xmi:type="utility:GIFFileGraphic" resourceName="platform:/plugin/TreeTransformerApplication/icons/full/obj30/TreeTransformValidateJSON.gif"/>
8+
<composition>
9+
<nodes xmi:type="ComIbmWSInput.msgnode:FCMComposite_1" xmi:id="FCMComposite_1_1" location="25,60" URLSpecifier="/ValidateJSON" messageDomainProperty="JSON" messageSetProperty="ModelJSON.json" validateTiming="immediate" validateMaster="contentAndValue">
10+
<translation xmi:type="utility:ConstantString" string="HTTP /ValidateJSON"/>
11+
</nodes>
12+
<nodes xmi:type="ComIbmCompute.msgnode:FCMComposite_1" xmi:id="FCMComposite_1_2" location="211,18" computeExpression="esql://routine/#TreeTransformerValidateJSON_Compute.Main">
13+
<translation xmi:type="utility:ConstantString" string="Compute"/>
14+
</nodes>
15+
<nodes xmi:type="ComIbmWSReply.msgnode:FCMComposite_1" xmi:id="FCMComposite_1_3" location="405,56">
16+
<translation xmi:type="utility:ConstantString" string="HTTP Reply"/>
17+
</nodes>
18+
<connections xmi:type="eflow:FCMConnection" xmi:id="FCMConnection_1" targetNode="FCMComposite_1_2" sourceNode="FCMComposite_1_1" sourceTerminalName="OutTerminal.failure" targetTerminalName="InTerminal.in"/>
19+
<connections xmi:type="eflow:FCMConnection" xmi:id="FCMConnection_2" targetNode="FCMComposite_1_3" sourceNode="FCMComposite_1_1" sourceTerminalName="OutTerminal.out" targetTerminalName="InTerminal.in"/>
20+
<connections xmi:type="eflow:FCMConnection" xmi:id="FCMConnection_3" targetNode="FCMComposite_1_3" sourceNode="FCMComposite_1_2" sourceTerminalName="OutTerminal.out" targetTerminalName="InTerminal.in"/>
21+
</composition>
22+
<propertyOrganizer/>
23+
<stickyBoard/>
24+
</eClassifiers>
25+
</ecore:EPackage>
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
2+
<MessagePool xmlns="http://wwww.ibm.com/iib/test/1.0.0">
3+
<InputMessage timestamp="1718873511452" nodeId="FCMComposite_1_1" name="Valid JSON" id="1718873511452-411">
4+
<plainText>%7B%22Problem%22%3A+%7B%22Description%22%3A%22This+is+a+short+summary+description%22%7D%7D</plainText>
5+
</InputMessage>
6+
<InputMessage timestamp="1718873433958" nodeId="FCMComposite_1_1" name="Invalid JSON" id="1718873433958-356">
7+
<plainText>%7B%22ThisFieldIsNotInTheJSONSchema%22%3A+%7B%22Description%22%3A%22This+is+a+short+summary+description%22%7D%7D</plainText>
8+
</InputMessage>
9+
</MessagePool>
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<ecore:EPackage xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:ComIbmCompute.msgnode="ComIbmCompute.msgnode" xmlns:ComIbmWSInput.msgnode="ComIbmWSInput.msgnode" xmlns:ComIbmWSReply.msgnode="ComIbmWSReply.msgnode" xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" xmlns:eflow="http://www.ibm.com/wbi/2005/eflow" xmlns:utility="http://www.ibm.com/wbi/2005/eflow_utility" nsURI="TreeTransformValidateXML.msgflow" nsPrefix="TreeTransformValidateXML.msgflow">
3+
<eClassifiers xmi:type="eflow:FCMComposite" name="FCMComposite_1" nodeLayoutStyle="RECTANGLE">
4+
<eSuperTypes href="http://www.ibm.com/wbi/2005/eflow#//FCMBlock"/>
5+
<translation xmi:type="utility:TranslatableString" key="TreeTransformValidateXML" bundleName="TreeTransformValidateXML" pluginId="TreeTransformerApplication"/>
6+
<colorGraphic16 xmi:type="utility:GIFFileGraphic" resourceName="platform:/plugin/TreeTransformerApplication/icons/full/obj16/TreeTransformValidateXML.gif"/>
7+
<colorGraphic32 xmi:type="utility:GIFFileGraphic" resourceName="platform:/plugin/TreeTransformerApplication/icons/full/obj30/TreeTransformValidateXML.gif"/>
8+
<composition>
9+
<nodes xmi:type="ComIbmWSInput.msgnode:FCMComposite_1" xmi:id="FCMComposite_1_1" location="102,75" URLSpecifier="/ValidateXML" messageDomainProperty="XMLNSC" validateTiming="immediate" validateMaster="contentAndValue">
10+
<translation xmi:type="utility:ConstantString" string="HTTP /ValidateXML"/>
11+
</nodes>
12+
<nodes xmi:type="ComIbmWSReply.msgnode:FCMComposite_1" xmi:id="FCMComposite_1_2" location="482,71">
13+
<translation xmi:type="utility:ConstantString" string="HTTP Reply"/>
14+
</nodes>
15+
<nodes xmi:type="ComIbmCompute.msgnode:FCMComposite_1" xmi:id="FCMComposite_1_3" location="288,33" computeExpression="esql://routine/#TreeTransformerValidateXML_Compute.Main">
16+
<translation xmi:type="utility:ConstantString" string="Compute"/>
17+
</nodes>
18+
<connections xmi:type="eflow:FCMConnection" xmi:id="FCMConnection_1" targetNode="FCMComposite_1_2" sourceNode="FCMComposite_1_1" sourceTerminalName="OutTerminal.out" targetTerminalName="InTerminal.in"/>
19+
<connections xmi:type="eflow:FCMConnection" xmi:id="FCMConnection_2" targetNode="FCMComposite_1_3" sourceNode="FCMComposite_1_1" sourceTerminalName="OutTerminal.failure" targetTerminalName="InTerminal.in"/>
20+
<connections xmi:type="eflow:FCMConnection" xmi:id="FCMConnection_3" targetNode="FCMComposite_1_2" sourceNode="FCMComposite_1_3" sourceTerminalName="OutTerminal.out" targetTerminalName="InTerminal.in"/>
21+
</composition>
22+
<propertyOrganizer/>
23+
<stickyBoard/>
24+
</eClassifiers>
25+
</ecore:EPackage>
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
2+
<MessagePool xmlns="http://wwww.ibm.com/iib/test/1.0.0">
3+
<InputMessage timestamp="1718873856042" nodeId="FCMComposite_1_1" name="Invalid XML" id="1718873856042-647">
4+
<plainText>%3CThisFieldIsNotInTheSchema%3E%0D%0A%3CDescription%3EThis+is+a+short+summary+description%3C%2FDescription%3E%0D%0A%3C%2FThisFieldIsNotInTheSchema%3E</plainText>
5+
</InputMessage>
6+
<InputMessage timestamp="1718873911043" nodeId="FCMComposite_1_1" name="Valid XML" id="1718873911043-718">
7+
<plainText>%3CProblem%3E%0D%0A%3CDescription%3EThis+is+a+short+summary+description%3C%2FDescription%3E%0D%0A%3C%2FProblem%3E</plainText>
8+
</InputMessage>
9+
</MessagePool>
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
2+
<MessagePool xmlns="http://wwww.ibm.com/iib/test/1.0.0">
3+
<InputMessage timestamp="1718874372065" nodeId="FCMComposite_1_1" name="Input" id="1718874372065-780">
4+
<plainText>%3CProblem%3E%0D%0A%3CDescription%3EBen+magical+new+description+2%3C%2FDescription%3E%0D%0A%3C%2FProblem%3E</plainText>
5+
</InputMessage>
6+
</MessagePool>
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
2+
3+
CREATE COMPUTE MODULE TreeTransformerValidateJSON_Compute
4+
CREATE FUNCTION Main() RETURNS BOOLEAN
5+
BEGIN
6+
CALL CopyMessageHeaders();
7+
SET OutputRoot.JSON.Data.Message.Feedback = 'The input message failed JSON validation';
8+
RETURN TRUE;
9+
END;
10+
11+
CREATE PROCEDURE CopyMessageHeaders() BEGIN
12+
DECLARE I INTEGER 1;
13+
DECLARE J INTEGER;
14+
SET J = CARDINALITY(InputRoot.*[]);
15+
WHILE I < J DO
16+
SET OutputRoot.*[I] = InputRoot.*[I];
17+
SET I = I + 1;
18+
END WHILE;
19+
END;
20+
21+
CREATE PROCEDURE CopyEntireMessage() BEGIN
22+
SET OutputRoot = InputRoot;
23+
END;
24+
END MODULE;

0 commit comments

Comments
 (0)