public boolean belongs(IPackageFragment fragment){
  if (fragment == null)   return false;
  if (fJavaProject.equals(fragment.getJavaProject())) {
    return fName.equals(fragment.getElementName());
  }
  return false;
}

public boolean belongs ( IPackageFragment fragment ) { if ( fragment == null ) return false ; if ( fJavaProject . equals ( fragment . getJavaProject ( ) ) ) { return fName . equals ( fragment . getElementName ( ) ) ; } return false ; }
returns true if the given fragment has the same name and resides inside the same project as the other fragments in the logicalpackage .
