Java String Sanitize sanitizeString(String s)

Here you can find the source of sanitizeString(String s)

Description

Clean any XML from the string

License

Apache License

Parameter

Parameter Description
s a parameter

Declaration

public static String sanitizeString(String s) 

Method Source Code

//package com.java2s;
//License from project: Apache License 

public class Main {
    /**//  ww w .  j  a  v a2 s .c  o m
     * Clean any XML from the string
     * @param s
     * @return
     */
    public static String sanitizeString(String s) {
        return s.replace("<", "").replace(">", "").replace("/>", "");
    }
}

Related

  1. sanitizeSingleQuotesInAlbumItemValues(String value)
  2. sanitizeString(final String s)
  3. sanitizeString(String dirtyString)
  4. sanitizeString(String input)
  5. sanitizeString(String s)
  6. sanitizeString(String s)
  7. sanitizeString(String str)
  8. sanitizeStringAsLiteral(String literal)
  9. sanitizeStringForXPath(String text)