org.springframework.plugin.core.PluginRegistry Java Examples

The following examples show how to use org.springframework.plugin.core.PluginRegistry. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: ModelCache.java    From Resource with GNU General Public License v3.0 6 votes vote down vote up
public Function<ResolvedType, ? extends ModelReference> getFactory()
{
    if (factory == null)
    {

        List<DefaultTypeNameProvider> providers = new ArrayList();
        providers.add(new DefaultTypeNameProvider());
        PluginRegistry<TypeNameProviderPlugin, DocumentationType> modelNameRegistry =
            OrderAwarePluginRegistry.create(providers);
        TypeNameExtractor typeNameExtractor = new TypeNameExtractor(
            typeResolver,
            modelNameRegistry,
            new JacksonEnumTypeDeterminer());
        ModelContext modelContext = inputParam(
            context.getGroupName(),
            String.class,
            context.getDocumentationType(),
            context.getAlternateTypeProvider(),
            context.getGenericsNamingStrategy(),
            context.getIgnorableParameterTypes());
        factory = ResolvedTypes.modelRefFactory(modelContext, typeNameExtractor);
    }
    return factory;
}
 
Example #2
Source File: BuildExecutor.java    From spring-data-dev-tools with Apache License 2.0 5 votes vote down vote up
public BuildExecutor(PluginRegistry<BuildSystem, Project> buildSystems, Logger logger,
		MavenProperties mavenProperties, ExecutorService buildExecutor) {

	this.buildSystems = buildSystems;
	this.mavenProperties = mavenProperties;

	if (this.mavenProperties.isParallelize()) {
		this.executor = buildExecutor;
	} else {
		this.executor = ImmediateExecutorService.INSTANCE;
	}
}
 
Example #3
Source File: LocalPluginProcessor.java    From fullstop with Apache License 2.0 5 votes vote down vote up
public LocalPluginProcessor(final FullstopPlugin fullstopPlugin) {
    Assert.notNull(fullstopPlugin, "Plugin should never be null");

    final List<FullstopPlugin> plugins = Lists.newArrayList();
    plugins.add(fullstopPlugin);
    final PluginRegistry<FullstopPlugin, CloudTrailEvent> pluginRegistry = SimplePluginRegistry.create(plugins);
    pluginEventProcessor = new PluginEventsProcessor(pluginRegistry);
}
 
Example #4
Source File: IssueTrackerConfiguration.java    From spring-data-dev-tools with Apache License 2.0 4 votes vote down vote up
@Bean
PluginRegistry<IssueTracker, Project> issueTrackers(List<? extends IssueTracker> plugins) {
	return OrderAwarePluginRegistry.create(plugins);
}
 
Example #5
Source File: PluginEventsProcessor.java    From fullstop with Apache License 2.0 4 votes vote down vote up
@Autowired
public PluginEventsProcessor(final PluginRegistry<FullstopPlugin, CloudTrailEvent> fullstopPluginRegistry) {
    this.fullstopPluginRegistry = fullstopPluginRegistry;
}
 
Example #6
Source File: RegisteredPluginLogger.java    From fullstop with Apache License 2.0 4 votes vote down vote up
@Autowired
public RegisteredPluginLogger(final PluginRegistry<FullstopPlugin, CloudTrailEvent> fullstopPluginRegistry) {
    this.fullstopPluginRegistry = fullstopPluginRegistry;
}