Java tutorial
//package com.java2s; // ProjectForge is dual-licensed. public class Main { /** * Replace all single quotes by quotation marks. This is use-ful for writing xml string constants e. g. in test cases. * <node name='name' locale='en'/> is transformed to <node name="name" locale="en"/> * @param xml * @return */ public static String replaceQuotes(final String xml) { final String text = xml.replace('\'', '"'); return text; } }