
public void transform(TransformationInput transformationInput, TransformationOutput transformationOutput) throws StreamTransformationException {
try {
InputStream inputstream = transformationInput.getInputPayload().getInputStream();
OutputStream outputstream = transformationOutput.getOutputPayload().getOutputStream();
byte[] b = new byte[inputstream.available()];
inputstream.read(b);
String encoding ="UTF-8";
String inputXML=new String(b);
inputXML = inputXML.replaceAll("&(?!amp;)", "&");
outputstream.write(inputXML.getBytes(encoding));
} catch (Exception exception) {
getTrace().addDebugMessage(exception.getMessage());
throw new StreamTransformationException(exception.toString());
}
}

You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
| User | Count |
|---|---|
| 29 | |
| 21 | |
| 19 | |
| 16 | |
| 14 | |
| 13 | |
| 13 | |
| 13 | |
| 11 | |
| 10 |