public List<EdxLocalParseChannel> filterForInactiveCourses(List<CourseEntry> courseEntryList){
  Set<String> activeCourseList=new HashSet<>();
  for (  CourseEntry entry : courseEntryList) {
    activeCourseList.add(entry.getId());
  }
  List<EdxLocalParseChannel> inactiveCourseList=new LinkedList<EdxLocalParseChannel>();
  for (  EdxLocalParseChannel pc : this) {
    if (!activeCourseList.contains(pc.getCourseId())) {
      inactiveCourseList.add(pc);
    }
  }
  return inactiveCourseList;
}

public List < EdxLocalParseChannel > filterForInactiveCourses ( List < CourseEntry > courseEntryList ) { Set < String > activeCourseList = new HashSet < > ( ) ; for ( CourseEntry entry : courseEntryList ) { activeCourseList . add ( entry . getId ( ) ) ; } List < EdxLocalParseChannel > inactiveCourseList = new LinkedList < EdxLocalParseChannel > ( ) ; for ( EdxLocalParseChannel pc : this ) { if ( ! activeCourseList . contains ( pc . getCourseId ( ) ) ) { inactiveCourseList . add ( pc ) ; } } return inactiveCourseList ; }
find all the course entry in saved preference which are not in the current active course list
