private static Attributes filterAttributes(IntSet indexSet,Attributes attributes){
  if (indexSet.size() == attributes.getLength())   return attributes;
  return new FilteredAttributes(indexSet,attributes);
}

private static Attributes filterAttributes ( IntSet indexSet , Attributes attributes ) { if ( indexSet . size ( ) == attributes . getLength ( ) ) return attributes ; return new FilteredAttributes ( indexSet , attributes ) ; }
get the filtered attributes . it checks if we want all the attributes and in that case returns the initial attributes , otherwise creates a filteredattributes instance based on the index set and on the attributes .
