本文整理汇总了Java中org.pf4j.DefaultPluginManager类的典型用法代码示例。如果您正苦于以下问题:Java DefaultPluginManager类的具体用法?Java DefaultPluginManager怎么用?Java DefaultPluginManager使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
DefaultPluginManager类属于org.pf4j包,在下文中一共展示了DefaultPluginManager类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: pluginStart
import org.pf4j.DefaultPluginManager; //导入依赖的package包/类
@Test
public void pluginStart() {
PluginManager manager = new DefaultPluginManager(Paths.get("export"));
manager.loadPlugins();
manager.enablePlugin("SliceLayoutCSVExporter");
manager.startPlugins();
Assert.assertTrue(manager.enablePlugin("SliceLayoutCSVExporter"));
}
示例2: pluginStart
import org.pf4j.DefaultPluginManager; //导入依赖的package包/类
@Test
public void pluginStart() {
PluginManager manager = new DefaultPluginManager(Paths.get("export"));
manager.loadPlugins();
manager.enablePlugin("VaultODVExporter");
manager.startPlugins();
Assert.assertTrue(manager.enablePlugin("VaultODVExporter"));
}
示例3: pluginStart
import org.pf4j.DefaultPluginManager; //导入依赖的package包/类
@Test
public void pluginStart() throws PluginException {
PluginManager manager = new DefaultPluginManager(Paths.get("export"));
manager.loadPlugins();
manager.enablePlugin("VaultCSVExporter");
manager.startPlugins();
Assert.assertTrue(manager.enablePlugin("VaultCSVExporter"));
}
示例4: pluginLoad
import org.pf4j.DefaultPluginManager; //导入依赖的package包/类
/**
* Test to see whether the plugin can be loaded.
*/
@Test
public void pluginLoad() {
PluginManager manager = new DefaultPluginManager(Paths.get("export"));
manager.loadPlugins();
Assert.assertTrue(0 != manager.getPlugins().size());
}
示例5: pluginStart
import org.pf4j.DefaultPluginManager; //导入依赖的package包/类
/**
* Test to see whether the plugin can be started.
*
* @throws PluginException If the plugin can not be started.
*/
@Test
public void pluginStart() throws PluginException {
PluginManager manager = new DefaultPluginManager(Paths.get("export"));
manager.loadPlugins();
manager.enablePlugin("SonySWR21Importer");
manager.startPlugins();
Assert.assertTrue(manager.enablePlugin("SonySWR21Importer"));
}
示例6: pluginStart
import org.pf4j.DefaultPluginManager; //导入依赖的package包/类
/**
* Test to see whether the plugin can be started.
*
* @throws PluginException If the plugin can not be started.
*/
@Test
public void pluginStart() throws PluginException {
PluginManager manager = new DefaultPluginManager(Paths.get("export"));
manager.loadPlugins();
manager.enablePlugin("LibreTextImporter");
manager.startPlugins();
Assert.assertTrue(manager.enablePlugin("LibreTextImporter"));
}
示例7: callPlugin
import org.pf4j.DefaultPluginManager; //导入依赖的package包/类
/**
* Test to see whether the plugin can be called and accessed.
*/
@Test
public void callPlugin() {
PluginManager manager = new DefaultPluginManager(Paths.get("export"));
manager.loadPlugins();
manager.enablePlugin("LibreTextImporter");
manager.startPlugin("LibreTextImporter");
Importer LibreTextImporter = manager.getExtensions(Importer.class).get(0);
LibreTextImporter.setImportFilePath("path/to/data");
Assert.assertFalse(LibreTextImporter.importData());
}
示例8: pluginStart
import org.pf4j.DefaultPluginManager; //导入依赖的package包/类
/**
* Test to see whether the plugin can be started.
*
* @throws PluginException If the plugin can not be started.
*/
@Test
public void pluginStart() throws PluginException {
PluginManager manager = new DefaultPluginManager(Paths.get("export"));
manager.loadPlugins();
manager.enablePlugin("MedtronicImporter");
manager.startPlugins();
Assert.assertTrue(manager.enablePlugin("MedtronicImporter"));
}
示例9: callPlugin
import org.pf4j.DefaultPluginManager; //导入依赖的package包/类
/**
* Test to see whether the plugin can be called and accessed.
*/
@Test
public void callPlugin() {
PluginManager manager = new DefaultPluginManager(Paths.get("export"));
manager.loadPlugins();
manager.enablePlugin("MedtronicImporter");
manager.startPlugin("MedtronicImporter");
Importer medtronicImporter = manager.getExtensions(Importer.class).get(0);
medtronicImporter.setImportFilePath("path/to/data");
Assert.assertFalse(medtronicImporter.importData());
}
示例10: pluginStart
import org.pf4j.DefaultPluginManager; //导入依赖的package包/类
/**
* Test to see whether the plugin can be started.
*
* @throws PluginException If the plugin can not be started.
*/
@Test
public void pluginStart() throws PluginException {
PluginManager manager = new DefaultPluginManager(Paths.get("export"));
manager.loadPlugins();
manager.enablePlugin("ODVDBJsonImporter");
manager.startPlugins();
Assert.assertTrue(manager.enablePlugin("ODVDBJsonImporter"));
}
示例11: getImporter
import org.pf4j.DefaultPluginManager; //导入依赖的package包/类
/**
* Returns an instance of the specified importer.
* @param importer The type of the importer to be returned.
* @return An instance of the specified importer.
*/
public static Importer getImporter(final String importer) {
PluginManager manager = new DefaultPluginManager(Paths.get("export"));
manager.loadPlugins();
manager.startPlugin(importer);
Assert.assertEquals(1, manager.getStartedPlugins().size());
Assert.assertEquals("please delete out folder, most of the time default plugin loader finds plugins on default classpath that are not wanted",1, manager.getExtensions(Importer.class).size());
return manager.getExtensions(Importer.class).get(0);
}
示例12: getExporter
import org.pf4j.DefaultPluginManager; //导入依赖的package包/类
/**
* Returns an instance of the specified exporter.
* @param exporter The type of the importer to be returned.
* @return An instance of the specified exporter.
*/
public static Exporter getExporter(final String exporter) {
PluginManager manager = new DefaultPluginManager(Paths.get("export"));
manager.loadPlugins();
manager.startPlugin(exporter);
Assert.assertEquals(1, manager.getStartedPlugins().size());
Assert.assertEquals("please delete out folder, most of the time default plugin loader finds plugins on default classpath that are not wanted",1, manager.getExtensions(Exporter.class).size());
return manager.getExtensions(Exporter.class).get(0);
}
示例13: pluginStart
import org.pf4j.DefaultPluginManager; //导入依赖的package包/类
/**
* Test to see whether the plugin can be started.
*
* @throws PluginException If the plugin can not be started.
*/
@Test
public void pluginStart() throws PluginException {
PluginManager manager = new DefaultPluginManager(Paths.get("export"));
manager.loadPlugins();
manager.enablePlugin("GoogleFitCSVImporter");
manager.startPlugins();
Assert.assertTrue(manager.enablePlugin("GoogleFitCSVImporter"));
}
示例14: callPlugin
import org.pf4j.DefaultPluginManager; //导入依赖的package包/类
/**
* Test to see whether the plugin can be called and accessed.
*/
@Test
public void callPlugin() {
PluginManager manager = new DefaultPluginManager(Paths.get("export"));
manager.loadPlugins();
manager.enablePlugin("GoogleFitCSVImporter");
manager.startPlugin("GoogleFitCSVImporter");
Importer googleFitCSVImporter = manager.getExtensions(Importer.class).get(0);
googleFitCSVImporter.setImportFilePath("path/to/data");
Assert.assertFalse(googleFitCSVImporter.importData());
}
示例15: pluginStart
import org.pf4j.DefaultPluginManager; //导入依赖的package包/类
/**
* Test to see whether the plugin can be started.
*
* @throws PluginException If the plugin can not be started.
*/
@Test
public void pluginStart() throws PluginException {
PluginManager manager = new DefaultPluginManager(Paths.get("export"));
manager.loadPlugins();
manager.enablePlugin("VaultODVImporter");
manager.startPlugins();
Assert.assertTrue(manager.enablePlugin("VaultODVImporter"));
}