Java Snipped help for ignorecaseequals

Hey friends i try to count some words in a csv file, this works really good, and i get some results, but the problem is about the small and big letters, how I should i change my code that it works right on counting words ?

 

 

if(
	(c_text.contains("ps4")) || ( c_text.contains("playstation4") ||
		( c_text.contains("playsi 4") || ( c_text.contains("playstation 4")||
			( c_text.contains("playsi4")))))){
				

		out_playsi_count = 1;
		}

		else {

			out_playsi_count = 0;
		}

 

I try it with ignorecaseequals, but there is always a error warning, also that way like c_text.equalsIgnoreCase(c_text) also dont work, because that method is boolean, and the c_text is String, got someone a advice for me please ?

 

 

thank you

 

Ayhan

 

You can use toUpperCase or toLowerCase before to use the contains function

How ???? u mean this, ? and always i get a error message about that is not boolean

I solved it 

 

 

(c_text.toLowerCase().contains("ayhan")) for example works good:) of course you need it also with 

(c_text.toUpperCase().contains("ayhan"))

Why do you need to do both?

important for both or ? big or small letters ?