Set<Usage> () { UsageView usageView = replaceContext.getUsageView(); Set<Usage> selectedUsages = usageView.getSelectedUsages(); selectedUsages.removeAll(usageView.getExcludedUsages()); return selectedUsages; }