Java String to SBC toSBC(String input)

Here you can find the source of toSBC(String input)

Description

to SBC

License

Open Source License

Declaration

public static String toSBC(String input) 

Method Source Code

//package com.java2s;

public class Main {

    public static String toSBC(String input) {
        if (input == null || input == "") {
            return "";
        }/*from   w  w w.  j  a  v a  2  s  . co  m*/
        char c[] = input.toCharArray();
        for (int i = 0; i < c.length; i++) {
            if (c[i] == ' ') {
                c[i] = '\u3000';
            } else if (c[i] < '\177') {
                c[i] = (char) (c[i] + 65248);

            }
        }
        return new String(c);
    }
}

Related

  1. ToSBC(String input)
  2. toSBC(String s)