Hi Team,
I need to handle some special characters like <,>,& etc.. from WS Adapter to CRM in PI 7.1.
http://www.sdn.sap.com/irj/scn/weblogs?blog=/pub/wlg/9420 [original link is broken]
By using the above blog i had implemented the Java Code as
public void execute(InputStream in, OutputStream out){
try{
int read_data;
while((read_data = in.read()) != -1){
if (read_data == '&'){
out.write("&".getBytes());
}else if (read_data == '>'){
out.write(">".getBytes());
}else if (read_data == '<'){
out.write("<".getBytes());
}else if (read_data == '/'){
out.write("⁄".getBytes());
}else if (read_data == '\''){
out.write("'".getBytes());
}
else { out.write(read_data);
}
}
out.flush();
} catch (Exception e){}
}
I had added this class file in Operational Mapping.
It is working if we have only one IF condition for & in while
Any suggestion
Thanks
Sriram