public StateInteractive extent_to_whole_components(){
  Set<Integer> curr_group_no_set=new TreeSet<Integer>();
  Iterator<BrdItem> it=items_list.iterator();
  while (it.hasNext()) {
    BrdItem curr_item=it.next();
    if (curr_item.get_component_no() > 0) {
      curr_group_no_set.add(curr_item.get_component_no());
    }
  }
  Set<BrdItem> new_selected_items=new TreeSet<BrdItem>();
  new_selected_items.addAll(items_list);
  Iterator<Integer> it2=curr_group_no_set.iterator();
  while (it2.hasNext()) {
    int curr_group_no=it2.next();
    new_selected_items.addAll(r_brd.get_component_items(curr_group_no));
  }
  if (new_selected_items.isEmpty()) {
    return return_state;
  }
  items_list=new_selected_items;
  actlog_start_scope(LogfileScope.EXTEND_TO_WHOLE_COMPONENTS);
  i_brd.repaint();
  return this;
}

public StateInteractive extent_to_whole_components ( ) { Set < Integer > curr_group_no_set = new TreeSet < Integer > ( ) ; Iterator < BrdItem > it = items_list . iterator ( ) ; while ( it . hasNext ( ) ) { BrdItem curr_item = it . next ( ) ; if ( curr_item . get_component_no ( ) > 0 ) { curr_group_no_set . add ( curr_item . get_component_no ( ) ) ; } } Set < BrdItem > new_selected_items = new TreeSet < BrdItem > ( ) ; new_selected_items . addAll ( items_list ) ; Iterator < Integer > it2 = curr_group_no_set . iterator ( ) ; while ( it2 . hasNext ( ) ) { int curr_group_no = it2 . next ( ) ; new_selected_items . addAll ( r_brd . get_component_items ( curr_group_no ) ) ; } if ( new_selected_items . isEmpty ( ) ) { return return_state ; } items_list = new_selected_items ; actlog_start_scope ( LogfileScope . EXTEND_TO_WHOLE_COMPONENTS ) ; i_brd . repaint ( ) ; return this ; }
select also all items belonging to any group of the current selected items .
