source: this post
//Retrieve the values
Set<String> set = myScores.getStringSet("key", null);
//Set the values
Set<String> set = new HashSet<String>();
set.addAll(listOfExistingScores);
scoreEditor.putStringSet("key", set);
scoreEditor.commit();
myScores
refers to sharedpreference?listOfExistingScores
refers to? is it ArrayList?scoreEditor
refers to ArrayList? or ListView? or custom ListView?According to that answser you can say that those three variable defines following things :
myScores :
As you said in op, it's shared preference variable. It holdes sharedpreference
.
listOfExistingScores :
It refers to the array declared by user. It is stored in hashset.
scoreEditor :
Score editor is sharedpreferences editor. You can read more details about it by given link.