java - Using a lot of String Comparisons... Is there a better method than simply .equals()? -



java - Using a lot of String Comparisons... Is there a better method than simply .equals()? -

i writing programme info intensive , requires considerable amount of string comparisons sense .equals() costly method. there more efficient method of comparing strings?

edit:

i have 2 csv files contain client related information. in these 2 csv files info recorded not same except name , address. (this not guaranteed that's exclusively different problem) tasked making programme identify matches in clients on these 2 csv files combine info given client , output master csv file info 2 files nowadays given client. asking equals method because way saw of tackling problem doing great deal of string comparisons along way. approach going to develop specific sort on csv prior entering programme puts lastly name (or address haven't figured out 1 better) in alphabetical order running binary search algorithm on clients or sort of pointer driven search desired client via lastly name , address. going done after had read 2 csv file , parsed info client object. after of comments looks question not string .equals() method rather there more efficient manner of comparing , compiling 2 client objects without having iterate through both csv files.

no. fastest (and reasonable) way compare strings .equals().

you might need rethink programme , see if there's alternative comparing ton of strings.

java string

Comments

Popular posts from this blog

php - Android app custom user registration and login with cookie using facebook sdk -

django - Access session in user model .save() -

php - .htaccess Multiple Rewrite Rules / Prioritizing -