public void customResultAvailable(Object result) { final PlatformControlCenter pcc2 = (PlatformControlCenter)result; // Transfer settings from pcc to pcc2 pcc.getProperties().addResultListener(new SwingDefaultResultListener(window) { public void customResultAvailable(Object result) { pcc2.setProperties((Properties)result).addResultListener(new SwingDefaultResultListener(window) { public void customResultAvailable(Object result) { pcc = pcc2; window.showPlatformPanel(pcc); } }); } }); } });
public void customExceptionOccurred(Exception exception) { if(event!=null) // Called internally with null -> ignore exception { super.customExceptionOccurred(exception); } } });
public void run() { customCommandAvailable(command); } });
public void run() { customResultAvailable(result); } });
/** * Called when the result is available. * @param result The result. */ final public void resultAvailable(final E result) { // Hack!!! When triggered from shutdown hook, swing might be terminated // and invokeLater has no effect (grrr). if(!SReflect.HAS_GUI || SwingUtilities.isEventDispatchThread())// || Starter.isShutdown()) // if(SwingUtilities.isEventDispatchThread()) { customResultAvailable(result); } else { SwingUtilities.invokeLater(new Runnable() { public void run() { customResultAvailable(result); } }); } }
public void customResultAvailable(Object result) { final PlatformControlCenter pcc2 = (PlatformControlCenter)result; // Transfer settings from pcc to pcc2 pcc.getProperties().addResultListener(new SwingDefaultResultListener(window) { public void customResultAvailable(Object result) { pcc2.setProperties((Properties)result).addResultListener(new SwingDefaultResultListener(window) { public void customResultAvailable(Object result) { pcc = pcc2; window.showPlatformPanel(pcc); } }); } }); } });
public void customExceptionOccurred(Exception exception) { if(event!=null) // Called internally with null -> ignore exception { super.customExceptionOccurred(exception); } } });
/** * Called when a command is available. */ final public void commandAvailable(final Object command) { // Hack!!! When triggered from shutdown hook, swing might be terminated // and invokeLater has no effect (grrr). if(!SReflect.HAS_GUI || SwingUtilities.isEventDispatchThread())// || Starter.isShutdown()) // if(SwingUtilities.isEventDispatchThread()) { customCommandAvailable(command); } else { // Thread.dumpStack(); SwingUtilities.invokeLater(new Runnable() { public void run() { customCommandAvailable(command); } }); } }
public void customResultAvailable(List<MechanismInfo> result) { acp.setMechanisms(result); secservice.getSelectedAcquisitionMechanism().addResultListener(new SwingDefaultResultListener<Integer>() { public void customResultAvailable(Integer sel) { acp.setSelectedMechanism(sel); } }); } });
public void run() { customExceptionOccurred(exception); } });
public void customResultAvailable(List<MechanismInfo> result) { acp.setMechanisms(result); secservice.getSelectedAcquisitionMechanism().addResultListener(new SwingDefaultResultListener<Integer>() { public void customResultAvailable(Integer sel) { acp.setSelectedMechanism(sel); } }); } });
public void customExceptionOccurred(Exception exception) { if(event!=null) // Called internally with null -> ignore exception { super.customExceptionOccurred(exception); } } });
public void customResultAvailable(ILibraryService ls) { ls.getClassLoader(sid.getResourceIdentifier()) .addResultListener(new SwingDefaultResultListener<ClassLoader>() { public void customResultAvailable(ClassLoader cl) { Class type = service.getType().getType(cl); // System.out.println("Found: "+service.getType().getTypeName()+" "+cl+" "+type); ret.setResult(type); } }); } });
public void customExceptionOccurred(Exception exception) { refreshing = false; ret.setResult(null); super.customExceptionOccurred(exception); } });
public void customResultAvailable(final Tuple2<IResourceIdentifier, Map<IResourceIdentifier, List<IResourceIdentifier>>> mydeps) { libservice.getRemovableLinks().addResultListener(new SwingDefaultResultListener<Set<Tuple2<IResourceIdentifier, IResourceIdentifier>>>(LibServiceBrowser.this) { public void customResultAvailable(Set<Tuple2<IResourceIdentifier, IResourceIdentifier>> reml) { jcc.setStatusText("Refreshing resource tree finished"); LibServiceBrowser.this.deps = mydeps.getSecondEntity(); LibServiceBrowser.this.remlinks = reml; // System.out.println("kukuku: "+reml); DefaultTreeModel mod = (DefaultTreeModel)ridtree.getModel(); // Create new if first time if(!(mod.getRoot() instanceof LazyNode) || force) { // Add nonmanged urls ridtree.removeAll(); LazyNode root = new LazyNode(ROOTTEXT); mod.setRoot(root); } else { ((LazyNode)mod.getRoot()).refresh(); } } }); } });
public void customExceptionOccurred(Exception exception) { refreshing = false; ret.setResult(null); super.customExceptionOccurred(exception); } });
public void customResultAvailable(final Tuple2<IResourceIdentifier, Map<IResourceIdentifier, List<IResourceIdentifier>>> mydeps) { libservice.getRemovableLinks().addResultListener(new SwingDefaultResultListener<Set<Tuple2<IResourceIdentifier, IResourceIdentifier>>>(LibServiceBrowser.this) { public void customResultAvailable(Set<Tuple2<IResourceIdentifier, IResourceIdentifier>> reml) { jcc.setStatusText("Refreshing resource tree finished"); LibServiceBrowser.this.deps = mydeps.getSecondEntity(); LibServiceBrowser.this.remlinks = reml; // System.out.println("kukuku: "+reml); DefaultTreeModel mod = (DefaultTreeModel)ridtree.getModel(); // Create new if first time if(!(mod.getRoot() instanceof LazyNode) || force) { // Add nonmanged urls ridtree.removeAll(); LazyNode root = new LazyNode(ROOTTEXT); mod.setRoot(root); } else { ((LazyNode)mod.getRoot()).refresh(); } } }); } });
public void customExceptionOccurred(Exception exception) { // System.out.println("aborted: "+exception); super.customExceptionOccurred(exception); customResultAvailable(null); } });
public void customResultAvailable(ILibraryService ls) { ls.getClassLoader(sid.getResourceIdentifier()) .addResultListener(new SwingDefaultResultListener<ClassLoader>() { public void customResultAvailable(ClassLoader cl) { Class type = service.getType().getType(cl); // System.out.println("Found: "+service.getType().getTypeName()+" "+cl+" "+type); internalSetService(type); } }); } });
public void customExceptionOccurred(Exception exception) { // System.out.println("aborted: "+exception); super.customExceptionOccurred(exception); customResultAvailable(null); } });