Iterate on a java set object . Iteration in this example use of Long objects . Actually the code is so simple to understand ,but the idea is used so frequent.
Code:
public void showSetOntent(Set<Long> setLongs){ if(setLongs==null || setLongs.isEmpty()){ return; }