編集の要約なし
編集の要約なし
1行目: 1行目:
([[String]]).equalsIgnoreCase [https://docs.oracle.com/javase/jp/8/docs/api/java/lang/String.html#equalsIgnoreCase-java.lang.String-]<br>
"[[String]]".equalsIgnoreCase [https://docs.oracle.com/javase/jp/8/docs/api/java/lang/String.html#equalsIgnoreCase-java.lang.String-]<br>
public boolean equalsIgnoreCase(String anotherString)
public boolean equalsIgnoreCase(String anotherString)



2019年6月9日 (日) 13:14時点における版

"String".equalsIgnoreCase [1]
public boolean equalsIgnoreCase(String anotherString)

ケースを無視して内容が等しいか真偽します。

String s1 = "hoge";
String s2 = "text";

if (s1.equalsIgnoreCase(s2)) {
    System.out.println("true");
}