202002062025——『String関連』
2129 ワード
//1. String
String(byte[] byte, int offset, int length);
String(char[] char, int offset, int count);
String(char[] value);
//2.
char charAt(int index);
String substring(int beginIndex, int endIndex);
boolean startsWith(String prefix);
boolean startsWith(String prefix, int toOffset);
//3.
int indexOf(String ch);//
int indexOf(String ch, int startIndex);
//4. repalce
String replace(oldChar, newChar);
String replaceAll(Rex, replacement);
String replaceFirst(Rex, replacement);
//5.
boolean isEmpty(); // length(); 0 -> true