Android String Remove rmvSpecial(String baseStr)

Here you can find the source of rmvSpecial(String baseStr)

Description

rmv Special

Declaration

public static String rmvSpecial(String baseStr) 

Method Source Code

//package com.java2s;

public class Main {
    public static final String[] SPECIAL_CHARACTER_CODES = new String[] {
            """, "<", ">", "&gt", "—", "@" };
    public static final String[] SPECIAL_CHARACTER_SYMBOLS = new String[] {
            "\"", "<", ">", ">", "\'", "@" };

    public static String rmvSpecial(String baseStr) {
        String rmvStr = baseStr;//  w  w  w  . j a v a2  s  . c om
        for (int i = 0; i < SPECIAL_CHARACTER_CODES.length; i++) {
            rmvStr = rmvStr.replaceAll(SPECIAL_CHARACTER_CODES[i],
                    SPECIAL_CHARACTER_SYMBOLS[i]);
        }
        return rmvStr;
    }
}

Related

  1. removeDuplicates(String[] first, String[] second)
  2. removeSpace(String str)
  3. removeSuffix(String str, String suffix)
  4. removeWhitespace(String str)
  5. rmvSpace(String baseStr)
  6. removeBlanks(String content)
  7. rmvBlankLines(String input)
  8. remove(String str, char remove)
  9. removeCharacters(String x, char... cs)