1 19 20 package org.netbeans.modules.tasklist.docscan; 21 22 import java.util.List ; 23 import java.util.Iterator ; 24 import java.util.ArrayList ; 25 26 import org.netbeans.modules.tasklist.suggestions.SuggestionList; 27 import org.netbeans.modules.tasklist.core.Task; 28 import org.netbeans.modules.tasklist.client.Suggestion; 29 30 31 36 final class SourceTasksList extends SuggestionList { 37 38 SourceTasksList() { 39 super(Integer.MAX_VALUE); 40 } 41 42 public void addRemove(List addList, List removeList, boolean append, 43 Task parent, Task after) { 44 45 List filtered = new ArrayList (addList); 46 Iterator it = filtered.iterator(); 47 while (it.hasNext()) { 48 Suggestion next = (Suggestion) it.next(); 49 if (next.getSeed() instanceof SourceTaskProvider) { 50 continue; 51 } else { 52 it.remove(); 53 } 54 } 55 56 super.addRemove(filtered, removeList, append, parent, after); 57 } 58 59 } 60 | Popular Tags |