data.setName(summary.getName()); tdm.getAttributeMap().putAttribute(pix);
            public void run()            {                addLoaderThread(controller,this);                int count = 1;                int total = refList.size();                                for(Iterator iter = refList.iterator(); (iter.hasNext() && !kill);)                {                    ImageSummary summary = (ImageSummary)iter.next();                                        try                    {                        Pixels pix = summary.getDefaultPixels().getPixels();                        Image image = ps.getThumbnail(pix);                        ImageData data = new ImageData();                        data.setID(pix.getID());                        ThumbnailDataModel tdm = new ThumbnailDataModel(data);                        // TODO: figure out strategy for adding attributes.  do it here?                        final Thumbnail t = new Thumbnail(image,tdm);                                                final int theCount = count;                        final int theTotal = total;                        Runnable addTask = new Runnable()                        {                            public void run()                            {                                model.addThumbnail(t);                                String message =                                    ProgressMessageFormatter.format("Loaded image %n of %t...",                                                            theCount,theTotal);                                status.processAdvanced(message);                            }                        };                        SwingUtilities.invokeLater(addTask);                        count++;                    }                    catch(ImageServerException ise)                    {                        UserNotifier un = registry.getUserNotifier();                        un.notifyError("ImageServer Error",ise.getMessage(),ise);                        status.processFailed("Error loading images.");                        return;                    }                }                                if(!kill)                {                    Runnable finalTask = new Runnable()                    {                        public void run()                        {                            status.processSucceeded("All images loaded.");                        }                    };                    SwingUtilities.invokeLater(finalTask);                    return;                }                removeLoaderThread(controller,this);            }