当前位置: 首页>>代码示例>>Java>>正文


Java ExtensionDef类代码示例

本文整理汇总了Java中org.jboss.arquillian.config.descriptor.api.ExtensionDef的典型用法代码示例。如果您正苦于以下问题:Java ExtensionDef类的具体用法?Java ExtensionDef怎么用?Java ExtensionDef使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


ExtensionDef类属于org.jboss.arquillian.config.descriptor.api包,在下文中一共展示了ExtensionDef类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: onGovernorExtensionConfigured

import org.jboss.arquillian.config.descriptor.api.ExtensionDef; //导入依赖的package包/类
public void onGovernorExtensionConfigured(@Observes GovernorExtensionConfigured event, ArquillianDescriptor arquillianDescriptor) throws Exception {
    final RedmineGovernorConfiguration redmineGovernorConfiguration = new RedmineGovernorConfiguration();

    for (final ExtensionDef extension : arquillianDescriptor.getExtensions()) {
        if (extension.getExtensionName().equals(EXTENSION_NAME)) {
            redmineGovernorConfiguration.setConfiguration(extension.getExtensionProperties());
            break;
        }
    }
    redmineGovernorConfiguration.validate();

    this.redmineGovernorConfiguration.set(redmineGovernorConfiguration);

    final RedmineGovernorClient redmineGovernorClient = new RedmineGovernorClientFactory().build(this.redmineGovernorConfiguration.get());

    this.redmineGovernorClient.set(redmineGovernorClient);
    this.redmineManager.set(redmineGovernorClient.getRedmineManager());

    logger.log(Level.CONFIG, "Configuration of Arquillian Redmine extension:");
    logger.log(Level.CONFIG, this.redmineGovernorConfiguration.get().toString());
}
 
开发者ID:arquillian,项目名称:arquillian-governor,代码行数:22,代码来源:RedmineGovernorConfigurator.java

示例2: onGovernorExtensionConfigured

import org.jboss.arquillian.config.descriptor.api.ExtensionDef; //导入依赖的package包/类
public void onGovernorExtensionConfigured(@Observes GovernorExtensionConfigured event, ArquillianDescriptor arquillianDescriptor) throws Exception {
    final SkipperConfiguration skipperConfiguration = new SkipperConfiguration();

    for (final ExtensionDef extension : arquillianDescriptor.getExtensions()) {
        if (extension.getExtensionName().equals(EXTENSION_NAME)) {
            skipperConfiguration.setConfiguration(extension.getExtensionProperties());
            skipperConfiguration.validate();
            break;
        }
    }

    this.skipperReportHolder.set(new SkipperReportHolder());
    this.skipperConfiguration.set(skipperConfiguration);

    logger.log(Level.CONFIG, "Configuration of Arquillian Skipper extension:");
    logger.log(Level.CONFIG, skipperConfiguration.toString());
}
 
开发者ID:arquillian,项目名称:arquillian-governor,代码行数:18,代码来源:SkipperConfigurator.java

示例3: onGovernorExtensionConfigured

import org.jboss.arquillian.config.descriptor.api.ExtensionDef; //导入依赖的package包/类
public void onGovernorExtensionConfigured(@Observes GovernorExtensionConfigured event, ArquillianDescriptor arquillianDescriptor) throws Exception {
    final JiraGovernorConfiguration jiraGovernorConfiguration = new JiraGovernorConfiguration();

    for (final ExtensionDef extension : arquillianDescriptor.getExtensions()) {
        if (extension.getExtensionName().equals(EXTENSION_NAME)) {
            jiraGovernorConfiguration.setConfiguration(extension.getExtensionProperties());
            jiraGovernorConfiguration.validate();
            break;
        }
    }

    this.jiraGovernorConfiguration.set(jiraGovernorConfiguration);

    final JiraGovernorClient jiraGovernorClient = new JiraGovernorClientFactory().build(this.jiraGovernorConfiguration.get());

    this.jiraGovernorClient.set(jiraGovernorClient);

    logger.log(Level.CONFIG, "Configuration of Arquillian JIRA extension:");
    logger.log(Level.CONFIG, jiraGovernorConfiguration.toString());
}
 
开发者ID:arquillian,项目名称:arquillian-governor,代码行数:21,代码来源:JiraGovernorConfigurator.java

示例4: onGovernorExtensionConfigured

import org.jboss.arquillian.config.descriptor.api.ExtensionDef; //导入依赖的package包/类
public void onGovernorExtensionConfigured(@Observes GovernorExtensionConfigured event, ArquillianDescriptor arquillianDescriptor) throws Exception {
    final GitHubGovernorConfiguration gitHubGovernorConfiguration = new GitHubGovernorConfiguration();

    for (final ExtensionDef extension : arquillianDescriptor.getExtensions()) {
        if (extension.getExtensionName().equals(EXTENSION_NAME)) {
            gitHubGovernorConfiguration.setConfiguration(extension.getExtensionProperties());
            gitHubGovernorConfiguration.validate();
            break;
        }
    }

    this.gitHubGovernorConfiguration.set(gitHubGovernorConfiguration);

    final GitHubGovernorClient gitHubGovernorClient = new GitHubGovernorClientFactory().build(this.gitHubGovernorConfiguration.get());

    this.gitHubGovernorClient.set(gitHubGovernorClient);
    this.gitHubClient.set(gitHubGovernorClient.getGitHubClient());

    logger.log(Level.CONFIG, "Configuration of Arquillian GitHub extension:");
    logger.log(Level.CONFIG, gitHubGovernorConfiguration.toString());
}
 
开发者ID:arquillian,项目名称:arquillian-governor,代码行数:22,代码来源:GitHubGovernorConfigurator.java

示例5: readMethodsFromConfiguration

import org.jboss.arquillian.config.descriptor.api.ExtensionDef; //导入依赖的package包/类
private Set<String> readMethodsFromConfiguration() {
    final Set<String> set = new HashSet<String>();
    final ArquillianDescriptor descriptor = desciptorInst.get();
    for (final ExtensionDef def : descriptor.getExtensions()) {
        if (def.getExtensionName().equalsIgnoreCase(EXTENSION_NAME)) {
            final Map<String, String> properties = def.getExtensionProperties();

            final String exp = properties.get(EXTENSION_PROPERTY_METHODS);
            if (exp != null) {
                set.addAll(Arrays.asList(exp.split(",")));
            }

            for (final Map.Entry<String, String> entry : properties.entrySet()) {
                if (entry.getKey().startsWith(EXTENSION_PROPERTY_METHODS + "_")) {
                    set.add(entry.getValue());
                }
            }
        }
    }
    return set;
}
 
开发者ID:arquillian,项目名称:arquillian-governor,代码行数:22,代码来源:IgnoreObserver.java

示例6: onArquillianDescriptor

import org.jboss.arquillian.config.descriptor.api.ExtensionDef; //导入依赖的package包/类
public void onArquillianDescriptor(@Observes ArquillianDescriptor arquillianDescriptor) throws GovernorConfigurationException {

        final GovernorConfiguration governorConfiguration = new GovernorConfiguration();

        for (final ExtensionDef extension : arquillianDescriptor.getExtensions()) {
            if (extension.getExtensionName().equals(EXTENSION_NAME)) {
                governorConfiguration.setConfiguration(extension.getExtensionProperties());
                governorConfiguration.validate();
                break;
            }
        }

        this.governorConfiguration.set(governorConfiguration);

        logger.log(Level.CONFIG, "Configuration of Arquillian Governor extension:");
        logger.log(Level.CONFIG, governorConfiguration.toString());

        governorExtensionConfiguredEvent.fire(new GovernorExtensionConfigured());
    }
 
开发者ID:arquillian,项目名称:arquillian-governor,代码行数:20,代码来源:GovernorConfigurator.java

示例7: configureExtension

import org.jboss.arquillian.config.descriptor.api.ExtensionDef; //导入依赖的package包/类
public void configureExtension(@Observes ArquillianDescriptor descriptor) {

        ReporterConfiguration configuration = new ReporterConfiguration();

        for (ExtensionDef extension : descriptor.getExtensions()) {
            if (extension.getExtensionName().equals(EXTENSION_NAME)) {
                configuration.setConfiguration(extension.getExtensionProperties());
                break;
            }
        }

        configuration.validate();

        this.configuration.set(configuration);

        if (LOGGER.isLoggable(Level.INFO)) {
            LOGGER.info("Configuration of Arquillian Reporting extension:");
            LOGGER.info(this.configuration.get().toString());
        }

        extensionConfigured.fire(new ReportingExtensionConfigured());
    }
 
开发者ID:arquillian,项目名称:arquillian-recorder,代码行数:23,代码来源:ReporterConfigurator.java

示例8: getBrowser

import org.jboss.arquillian.config.descriptor.api.ExtensionDef; //导入依赖的package包/类
private String getBrowser(ArquillianDescriptor arquillianDescriptor) {
    final ExtensionDef extension = arquillianDescriptor.extension("webdriver");

    if (extension == null) {
        return DEFAULT_BROWSER;
    }

    final Map<String, String> extensionProperties = extension.getExtensionProperties();

    if (extensionProperties == null) {
        return DEFAULT_BROWSER;
    }

    if (extensionProperties.containsKey("browser")) {
        return extensionProperties.get("browser");
    } else {
        return DEFAULT_BROWSER;
    }
}
 
开发者ID:arquillian,项目名称:arquillian-cube,代码行数:20,代码来源:InstallSeleniumCube.java

示例9: getDeploymentClass

import org.jboss.arquillian.config.descriptor.api.ExtensionDef; //导入依赖的package包/类
private Class<?> getDeploymentClass(ArquillianDescriptor descriptor) {
    if (descriptor == null) {
        throw new IllegalArgumentException("Descriptor must be specified");
    }
    ExtensionDef suite = descriptor.extension("suite");
    if (suite == null) {
        throw new IllegalArgumentException("Missing suite extension in arquillian.xml");
    }
    String className = suite.getExtensionProperties().get("deploymentClass");
    if (className == null) {
        throw new IllegalArgumentException("A extension element with property deploymentClass must be specified in arquillian.xml");
    }
    try {
        return Class.forName(className);
    } catch (ClassNotFoundException e) {
        throw new RuntimeException("Could not load defined deploymentClass: " + className, e);
    }
}
 
开发者ID:GoogleCloudPlatform,项目名称:appengine-tck,代码行数:19,代码来源:ArquillianSuiteExtension.java

示例10: initAsciidoctor

import org.jboss.arquillian.config.descriptor.api.ExtensionDef; //导入依赖的package包/类
private void initAsciidoctor(ArquillianDescriptor arquillianDescriptor) {

        for (final ExtensionDef extensionDef : arquillianDescriptor.getExtensions()) {
            if (extensionDef.getExtensionName().startsWith("asciidoctor")) {
               String gemPath = get(extensionDef.getExtensionProperties(), "gemPath", "");
               Asciidoctor asciidoctor = asciidoctorMap.get(gemPath);
               if(asciidoctor == null){
                   asciidoctor = Asciidoctor.Factory.create((File.separatorChar == '\\') ? gemPath.replaceAll("\\\\", "/") : gemPath);
                   asciidoctorMap.put(gemPath,asciidoctor);
               }
            }
        }
    }
 
开发者ID:cukespace,项目名称:arquillian-asciidoctor-extension,代码行数:14,代码来源:AsciidoctorObserver.java

示例11: renderAll

import org.jboss.arquillian.config.descriptor.api.ExtensionDef; //导入依赖的package包/类
private void renderAll(final ArquillianDescriptor descriptor) {
    for (final ExtensionDef extensionDef : descriptor.getExtensions()) {
        if (extensionDef.getExtensionName().startsWith("asciidoctor")) {
            long initialTime = System.currentTimeMillis();
            try {
                render(extensionDef.getExtensionName(), extensionDef.getExtensionProperties());
            }finally {
                getLogger().info(String.format("Execution time for extension %s: %d milliseconds", extensionDef.getExtensionName(), System.currentTimeMillis() - initialTime));
            }
        }
    }
}
 
开发者ID:cukespace,项目名称:arquillian-asciidoctor-extension,代码行数:13,代码来源:AsciidoctorObserver.java

示例12: getConfiguration

import org.jboss.arquillian.config.descriptor.api.ExtensionDef; //导入依赖的package包/类
private Map<String, String> getConfiguration() {
	for (ExtensionDef def : descriptor.get().getExtensions()) {
		if (SystemProperties.EXTENSION_NAME.equalsIgnoreCase(def
				.getExtensionName())) {
			return def.getExtensionProperties();
		}
	}
	return new HashMap<String, String>();
}
 
开发者ID:Blazebit,项目名称:blaze-storage,代码行数:10,代码来源:ArchiveProcessor.java

示例13: readExpressionFromConfiguration

import org.jboss.arquillian.config.descriptor.api.ExtensionDef; //导入依赖的package包/类
private String readExpressionFromConfiguration() {
    final ArquillianDescriptor descriptor = desciptorInst.get();
    for (final ExtensionDef def : descriptor.getExtensions()) {
        if (def.getExtensionName().equalsIgnoreCase(EXTENSION_NAME)) {
            final String exp = def.getExtensionProperties().get(EXTENSION_PROPERTY_EXP);
            if (exp != null) {
                return exp;
            }
        }
    }
    return null;
}
 
开发者ID:arquillian,项目名称:arquillian-governor,代码行数:13,代码来源:IgnoreObserver.java

示例14: getExtensionReports

import org.jboss.arquillian.config.descriptor.api.ExtensionDef; //导入依赖的package包/类
private Collection<? extends ExtensionReport> getExtensionReports(ArquillianDescriptor descriptor) {
    List<ExtensionReport> extensionReports = new ArrayList<ExtensionReport>();

    for (ExtensionDef extensionDef : descriptor.getExtensions()) {
        ExtensionReport extensionReport = new ExtensionReport();
        extensionReport.setQualifier(extensionDef.getExtensionName());
        extensionReport.setConfiguration(extensionDef.getExtensionProperties());
        extensionReports.add(extensionReport);
    }
    return extensionReports;
}
 
开发者ID:arquillian,项目名称:arquillian-recorder,代码行数:12,代码来源:ReporterLifecycleObserver.java

示例15: afterVideoExtensionConfigured

import org.jboss.arquillian.config.descriptor.api.ExtensionDef; //导入依赖的package包/类
public void afterVideoExtensionConfigured(@Observes VideoExtensionConfigured event, ArquillianDescriptor descriptor) {
    VideoConfiguration configuration = new DesktopVideoConfiguration(reporterConfiguration.get());

    for (ExtensionDef extension : descriptor.getExtensions()) {
        if (extension.getExtensionName().equals(EXTENSION_NAME)) {
            configuration.setConfiguration(extension.getExtensionProperties());
            break;
        }
    }

    configuration.validate();
    this.configuration.set(configuration);

    if (LOGGER.isLoggable(Level.INFO)) {
        LOGGER.info("Configuration of Arquillian Desktop Video Recorder:");
        LOGGER.info(this.configuration.get().toString());
    }

    // there will be 2 strategies in this list at least - SkippingVideoStrategy and DefaultVideoStrategy
    // if this extension is not on the class path, SkippingVideoStrategy was already produced hence
    // the extension will work in a "dummy" mode where nothing will be ever recorded. If this is on the class path,
    // we have recorder implementation hence we will use at least DefaultVideoStrategy if no other strategy is used

    List<VideoStrategy> strategies = new ArrayList<VideoStrategy>(serviceLoader.get().all(VideoStrategy.class));

    strategy.set(resolveVideoStrategy(strategies));

    strategy.get().setConfiguration(this.configuration.get());

    setup();
}
 
开发者ID:arquillian,项目名称:arquillian-recorder,代码行数:32,代码来源:DesktopVideoRecorderConfigurator.java


注:本文中的org.jboss.arquillian.config.descriptor.api.ExtensionDef类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。