package ijx.plugin;

import imagej.plugin.api.PluginEntry;
import imagej.plugin.spi.PluginFinder;

import java.util.ArrayList;
import java.util.Collection;
import java.util.List;

import org.openide.util.Lookup;

public class PluginDiscovery {

	/**
	 * Tests the plugin discovery mechanism,
	 * printing a list of all discovered plugins.
	 */
	public static void main(String[] args) {
		System.out.println("Scanning for plugin finders...");
		Collection<? extends PluginFinder> finders =
			Lookup.getDefault().lookupAll(PluginFinder.class);

		List<PluginEntry> plugins = new ArrayList<PluginEntry>();

		for (PluginFinder finder : finders) {
			System.out.println("Querying " + finder + "...");
			finder.findPlugins(plugins);
		}
		System.out.println("Discovered plugins:");
		for (PluginEntry plugin : plugins) {
			System.out.println("\t" + plugin);
		}
	}

}

package ijx.plugin;

import imagej.plugin.PluginEntry;
import imagej.plugin.PluginFinder;

import java.util.ArrayList;
import java.util.Collection;
import java.util.List;

import org.openide.util.Lookup;

public class PluginDiscovery {

	/**
	 * Tests the plugin discovery mechanism,
	 * printing a list of all discovered plugins.
	 */
	public static void main(String[] args) {
		System.out.println("Scanning for plugin finders...");
		Collection<? extends PluginFinder> finders =
			Lookup.getDefault().lookupAll(PluginFinder.class);

		List<PluginEntry> plugins = new ArrayList<PluginEntry>();

		for (PluginFinder finder : finders) {
			System.out.println("Querying " + finder + "...");
			finder.findPlugins(plugins);
		}
		System.out.println("Discovered plugins:");
		for (PluginEntry plugin : plugins) {
			System.out.println("\t" + plugin);
		}
	}

}

--- 
+++ 
@@ -1,7 +1,7 @@
 package ijx.plugin;
 
-import imagej.plugin.PluginEntry;
-import imagej.plugin.PluginFinder;
+import imagej.plugin.api.PluginEntry;
+import imagej.plugin.spi.PluginFinder;
 
 import java.util.ArrayList;
 import java.util.Collection;
Update package names in ijx.

This used to be revision r2172.
