當前位置: 首頁>>代碼示例>>Java>>正文


Java DefaultPluginManager類代碼示例

本文整理匯總了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"));
}
 
開發者ID:lucasbuschlinger,項目名稱:BachelorPraktikum,代碼行數:9,代碼來源:SliceLayoutCSVExporterTest.java

示例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"));
}
 
開發者ID:lucasbuschlinger,項目名稱:BachelorPraktikum,代碼行數:9,代碼來源:VaultODVExporterTest.java

示例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"));
}
 
開發者ID:lucasbuschlinger,項目名稱:BachelorPraktikum,代碼行數:9,代碼來源:VaultCSVExporterTest.java

示例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());
}
 
開發者ID:lucasbuschlinger,項目名稱:BachelorPraktikum,代碼行數:10,代碼來源:SonySWR21ImporterTest.java

示例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"));
}
 
開發者ID:lucasbuschlinger,項目名稱:BachelorPraktikum,代碼行數:14,代碼來源:SonySWR21ImporterTest.java

示例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"));
}
 
開發者ID:lucasbuschlinger,項目名稱:BachelorPraktikum,代碼行數:14,代碼來源:LibreTextImporterTest.java

示例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());
}
 
開發者ID:lucasbuschlinger,項目名稱:BachelorPraktikum,代碼行數:14,代碼來源:LibreTextImporterTest.java

示例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"));
}
 
開發者ID:lucasbuschlinger,項目名稱:BachelorPraktikum,代碼行數:14,代碼來源:MedtronicImporterTest.java

示例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());
}
 
開發者ID:lucasbuschlinger,項目名稱:BachelorPraktikum,代碼行數:14,代碼來源:MedtronicImporterTest.java

示例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"));
}
 
開發者ID:lucasbuschlinger,項目名稱:BachelorPraktikum,代碼行數:14,代碼來源:ODVDBJsonImporterTest.java

示例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);

}
 
開發者ID:lucasbuschlinger,項目名稱:BachelorPraktikum,代碼行數:15,代碼來源:TestImporterUtil.java

示例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);

}
 
開發者ID:lucasbuschlinger,項目名稱:BachelorPraktikum,代碼行數:15,代碼來源:TestImporterUtil.java

示例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"));
}
 
開發者ID:lucasbuschlinger,項目名稱:BachelorPraktikum,代碼行數:14,代碼來源:GoogleFitCSVImporterTest.java

示例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());
}
 
開發者ID:lucasbuschlinger,項目名稱:BachelorPraktikum,代碼行數:14,代碼來源:GoogleFitCSVImporterTest.java

示例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"));
}
 
開發者ID:lucasbuschlinger,項目名稱:BachelorPraktikum,代碼行數:14,代碼來源:VaultODVImporterTest.java


注:本文中的org.pf4j.DefaultPluginManager類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。