package mimaxue;
public class StrBinaryTurn {
//將Unicode字串轉換成bool型陣列
public boolean[] StrToBool(String input){
boolean[] output=Binstr16ToBool(BinstrToBinstr16(StrToBinstr(input)));
return output;
}
//將bool型陣列轉換成Unicode字串
public String BoolToStr(boolean[] input){
String output=BinstrToStr(Binstr16ToBinstr(BoolToBinstr16(input)));
//將字串轉換成二進位制字串,以空格相隔
private String StrToBinstr(String str) {
char[] strChar=str.toCharArray();
String result="";
for(int i=0;i
package mimaxue;
public class StrBinaryTurn {
//將Unicode字串轉換成bool型陣列
public boolean[] StrToBool(String input){
boolean[] output=Binstr16ToBool(BinstrToBinstr16(StrToBinstr(input)));
return output;
}
//將bool型陣列轉換成Unicode字串
public String BoolToStr(boolean[] input){
String output=BinstrToStr(Binstr16ToBinstr(BoolToBinstr16(input)));
return output;
}
//將字串轉換成二進位制字串,以空格相隔
private String StrToBinstr(String str) {
char[] strChar=str.toCharArray();
String result="";
for(int i=0;i