(Category)controller.getCategories(group).get(i);
(Category)controller.getCategories(group).get(selectedCategory);
            public void valueChanged(ListSelectionEvent e)            {                int i = categoryList.getSelectedIndex();                CategoryGroup group =                    (CategoryGroup)controller.getCategoryGroups().get(selectedGroup);                Category cat =                    (Category)controller.getCategories(group).get(i);                repaint();            }