I have two lists:
List<SomeObject> objectList;List<String> stringList;
While SomeObject has a member name which is of type String.
What is the best way to check if stringList contains a string that is not a name of any someObject in objectList?
Iterate through the objects in objectList and add each name to a
Set<String>(let’s call itnameSet). Then callnameSet.containsAll(stringList).