Search in sources :

Example 16 with MetadataDependencyRegistryTracker

use of org.springframework.roo.metadata.internal.MetadataDependencyRegistryTracker in project spring-roo by spring-projects.

the class ThymeleafMainControllerMetadataProviderImpl method activate.

/**
 * This service is being activated so setup it:
 * <ul>
 * <li>Create and open the {@link MetadataDependencyRegistryTracker}.</li>
 * <li>Create and open the {@link CustomDataKeyDecoratorTracker}.</li>
 * <li>Registers {@link RooJavaType#ROO_THYMELEAF_MAIN_CONTROLLER} as additional
 * JavaType that will trigger metadata registration.</li>
 * <li>Set ensure the governor type details represent a class.</li>
 * </ul>
 */
@Override
@SuppressWarnings("unchecked")
protected void activate(final ComponentContext cContext) {
    super.activate(cContext);
    context = cContext.getBundleContext();
    this.registryTracker = new MetadataDependencyRegistryTracker(context, this, PhysicalTypeIdentifier.getMetadataIdentiferType(), getProvidesType());
    this.registryTracker.open();
    addMetadataTrigger(ROO_THYMELEAF_MAIN_CONTROLLER);
}
Also used : MetadataDependencyRegistryTracker(org.springframework.roo.metadata.internal.MetadataDependencyRegistryTracker)

Example 17 with MetadataDependencyRegistryTracker

use of org.springframework.roo.metadata.internal.MetadataDependencyRegistryTracker in project spring-roo by spring-projects.

the class JSONMetadataProviderImpl method activate.

/**
 * This service is being activated so setup it:
 * <ul>
 * <li>Create and open the {@link MetadataDependencyRegistryTracker}.</li>
 * <li>Create and open the {@link CustomDataKeyDecoratorTracker}.</li>
 * <li>Registers {@link RooJavaType#ROO_JSON} as additional JavaType that
 * will trigger metadata registration.</li>
 * <li>Set ensure the governor type details represent a class.</li>
 * </ul>
 */
@Override
protected void activate(final ComponentContext cContext) {
    super.activate(cContext);
    context = cContext.getBundleContext();
    serviceInstaceManager.activate(this.context);
    this.registryTracker = new MetadataDependencyRegistryTracker(context, this, PhysicalTypeIdentifier.getMetadataIdentiferType(), getProvidesType());
    this.registryTracker.open();
    addMetadataTrigger(RooJavaType.ROO_JSON);
}
Also used : MetadataDependencyRegistryTracker(org.springframework.roo.metadata.internal.MetadataDependencyRegistryTracker)

Example 18 with MetadataDependencyRegistryTracker

use of org.springframework.roo.metadata.internal.MetadataDependencyRegistryTracker in project spring-roo by spring-projects.

the class JsonControllerIntegrationTestMetadataProviderImpl method activate.

/**
 * This service is being activated so setup it:
 * <ul>
 * <li>Create and open the {@link MetadataDependencyRegistryTracker}.</li>
 * <li>Registers {@link RooJavaType#ROO_JSON_CONTROLLER_INTEGRATION_TEST} as
 * additional JavaType that will trigger metadata registration.</li>
 * </ul>
 */
@Override
protected void activate(final ComponentContext cContext) {
    super.activate(cContext);
    this.registryTracker = new MetadataDependencyRegistryTracker(cContext.getBundleContext(), this, PhysicalTypeIdentifier.getMetadataIdentiferType(), getProvidesType());
    this.registryTracker.open();
    addMetadataTrigger(ROO_JSON_CONTROLLER_INTEGRATION_TEST);
}
Also used : MetadataDependencyRegistryTracker(org.springframework.roo.metadata.internal.MetadataDependencyRegistryTracker)

Example 19 with MetadataDependencyRegistryTracker

use of org.springframework.roo.metadata.internal.MetadataDependencyRegistryTracker in project spring-roo by spring-projects.

the class LinkFactoryMetadataProviderImpl method activate.

/**
 * This service is being activated so setup it:
 *
 * * Create and open the MetadataDependencyRegistryTracker.
 * * Create and open the CustomDataKeyDecoratorTracker.
 * * Registers RooJavaType.ROO_LINK_FACTORY as additional JavaType that
 * will trigger metadata registration.
 * * Set ensure the governor type details represent a class.
 */
@Override
protected void activate(final ComponentContext cContext) {
    super.activate(cContext);
    this.registryTracker = new MetadataDependencyRegistryTracker(cContext.getBundleContext(), this, PhysicalTypeIdentifier.getMetadataIdentiferType(), getProvidesType());
    this.registryTracker.open();
    addMetadataTrigger(RooJavaType.ROO_LINK_FACTORY);
}
Also used : MetadataDependencyRegistryTracker(org.springframework.roo.metadata.internal.MetadataDependencyRegistryTracker)

Example 20 with MetadataDependencyRegistryTracker

use of org.springframework.roo.metadata.internal.MetadataDependencyRegistryTracker in project spring-roo by spring-projects.

the class ThymeleafUIConfigurationMetadataProviderImpl method activate.

/**
 * This service is being activated so setup it:
 * <ul>
 * <li>Create and open the {@link MetadataDependencyRegistryTracker}.</li>
 * <li>Create and open the {@link CustomDataKeyDecoratorTracker}.</li>
 * <li>Registers {@link RooJavaType#ROO_THYMELEAF} as additional JavaType
 * that will trigger metadata registration.</li>
 * <li>Set ensure the governor type details represent a class.</li>
 * </ul>
 */
@Override
protected void activate(final ComponentContext cContext) {
    context = cContext.getBundleContext();
    super.activate(cContext);
    this.registryTracker = new MetadataDependencyRegistryTracker(context, this, PhysicalTypeIdentifier.getMetadataIdentiferType(), getProvidesType());
    this.registryTracker.open();
    addMetadataTrigger(ROO_WEB_MVC_THYMELEAF_UI_CONFIGURATION);
}
Also used : MetadataDependencyRegistryTracker(org.springframework.roo.metadata.internal.MetadataDependencyRegistryTracker)

Aggregations

MetadataDependencyRegistryTracker (org.springframework.roo.metadata.internal.MetadataDependencyRegistryTracker)47 BundleContext (org.osgi.framework.BundleContext)6 CustomDataKeyDecoratorTracker (org.springframework.roo.classpath.customdata.taggers.CustomDataKeyDecoratorTracker)6 LayerTypeMatcher (org.springframework.roo.classpath.layers.LayerTypeMatcher)5 JavaSymbolName (org.springframework.roo.model.JavaSymbolName)5 ConfigurableMetadataProvider (org.springframework.roo.addon.configurable.addon.ConfigurableMetadataProvider)2 ItdTriggerBasedMetadataProviderTracker (org.springframework.roo.classpath.itd.ItdTriggerBasedMetadataProviderTracker)2 Bundle (org.osgi.framework.Bundle)1 SerializableMetadataProvider (org.springframework.roo.addon.javabean.addon.SerializableMetadataProvider)1 MetadataDependency (org.springframework.roo.metadata.MetadataDependency)1