<edmx:Edmx
xmlns:edmx="http://schemas.microsoft.com/ado/2007/06/edmx"
xmlns:sap="http://www.sap.com/Protocols/SAPData" Version="1.0">
<edmx:DataServices
xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" m:DataServiceVersion="2.0">
<Schema
xmlns="http://schemas.microsoft.com/ado/2008/09/edm" Namespace="S1">
<EntityContainer Name="EC1" m:IsDefaultEntityContainer="true">
<EntitySet Name="MultiplySOAPSet" EntityType="S1.MultiplySOAP"></EntitySet>
<EntitySet Name="MultiplyRESTSet" EntityType="S1.MultiplyREST"></EntitySet>
</EntityContainer>
<EntityType Name="MultiplySOAP">
<Documentation/>
<Key>
<PropertyRef Name="SOAP1"></PropertyRef>
</Key>
<Property Name="SOAP1" Type="Edm.String" Nullable="false"></Property>
<Property Name="SOAP2" Type="Edm.String" Nullable="true"></Property>
<Property Name="SOAPResult" Type="Edm.String" Nullable="true"></Property>
</EntityType>
<EntityType Name="MultiplyREST">
<Documentation/>
<Key>
<PropertyRef Name="REST1"></PropertyRef>
</Key>
<Property Name="REST1" Type="Edm.String" Nullable="false"></Property>
<Property Name="REST2" Type="Edm.String" Nullable="true"></Property>
<Property Name="RESTResult" Type="Edm.String" Nullable="true"></Property>
</EntityType>
</Schema>
</edmx:DataServices>
</edmx:Edmx>
import com.sap.gateway.ip.core.customdev.util.Message;
import java.util.HashMap;
def Message processData(Message message) {
//Body
def body = message.getBody(java.io.Reader);
def string = message.getBody(java.lang.String);
//Properties
map = message.getProperties();
REST1 = map.get("REST1");
REST2 = map.get("REST2");
message.setBody(
"<MultiplyRESTSet>" +
"<MultiplyREST>" +
"<REST1>" + REST1 + "</REST1>" +
"<REST2>" + REST2 + "</REST2>" +
"<RESTResult>" + string + "</RESTResult>" +
"</MultiplyREST>" +
"</MultiplyRESTSet>");
return message;
}
<?xml version="1.0" encoding="utf-8"?>
<entry xmlns="http://www.w3.org/2005/Atom" xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices">
<content type="application/xml">
<m:properties>
<d:REST1>10</d:REST1>
<d:REST2>275</d:REST2>
</m:properties>
</content>
</entry>
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
8 | |
8 | |
7 | |
6 | |
5 | |
4 | |
4 | |
4 | |
3 | |
3 |