private Set<URI> andUriSet(Set<URI> set1,Set<URI> set2){
  HashSet<URI> resultSet=new HashSet<URI>();
  for (  URI uri : set1) {
    if (set2.contains(uri)) {
      resultSet.add(uri);
    }
  }
  return resultSet;
}

private Set < URI > andUriSet ( Set < URI > set1 , Set < URI > set2 ) { HashSet < URI > resultSet = new HashSet < URI > ( ) ; for ( URI uri : set1 ) { if ( set2 . contains ( uri ) ) { resultSet . add ( uri ) ; } } return resultSet ; }
ands the first set with the second and returns the result
