Annotation Interface EnableAcrossContext


@Retention(RUNTIME) @Target(TYPE) @Documented @Import(AcrossContextConfiguration.class) public @interface EnableAcrossContext
Using this annotation on a Configuration class will automatically create an AcrossContext using the settings from this annotation.
See Also:
  • Element Details

    • value

      String[] value
      Alias for the modules() attribute. Allows for more concise annotation declarations.
      Default:
      {}
    • modules

      String[] modules
      Array of AcrossModule names that should be configured if auto configuration is enabled. These will be added to the AcrossContext before any configured module beans and before the AcrossContextConfigurer instances are called.
      Default:
      {}
    • excludeFromScanning

      String[] excludeFromScanning
      Array of AcrossModule names that should never be resolved through scanning, no matter the values of scanForRequiredModules() and scanForOptionalModules().
      Default:
      {}
    • autoConfigure

      boolean autoConfigure
      Configures auto configuration of the AcrossContext. Auto configuration means AcrossModule beans from the parent ApplicationContext will be picked up and class path scanning for modules by names will be supported. The configured context will have a ClassPathScanningModuleDependencyResolver set to resolve the module dependencies as well.

      The ability to disable auto configuration is mainly kept for compatibility reasons.

      Default:
      true
    • scanForRequiredModules

      boolean scanForRequiredModules
      If auto configuration is enabled, should required modules be scanned for? All modules configured using the modules() attribute are considered to be required.
      Default:
      true
    • scanForOptionalModules

      boolean scanForOptionalModules
      If auto configuration is enabled, should optional modules be scanned for?
      Default:
      false
    • modulePackages

      String[] modulePackages
      Set of packages that should be scanned for modules. The standard modules packages as well as the package of the importing class will be used as well. If you do not want this, you should add . (dot) as a package name. In that case only explicitly defined module packages will be used.
      Default:
      {}
    • modulePackageClasses

      Class<?>[] modulePackageClasses
      Type-safe alternative to modulePackages() for specifying the packages to scan for modules. The package of each class specified will be scanned.

      Consider creating a special no-op marker class or interface in each package that serves no purpose other than being referenced by this attribute.

      The default packages will always apply as well, if you do not want this you should define . (dot) in modulePackages()

      .
      Default:
      {}
    • moduleConfigurationPackages

      String[] moduleConfigurationPackages
      Set of packages that should be scanned for ModuleConfiguration classes. If empty the sub-packages config and extensions of the importing class will be used.
      Default:
      {}
    • moduleConfigurationPackageClasses

      Class<?>[] moduleConfigurationPackageClasses
      Type-safe alternative to moduleConfigurationPackages() for specifying the packages to scan for ModuleConfiguration classes. The package of each class specified will be scanned.

      Consider creating a special no-op marker class or interface in each package that serves no purpose other than being referenced by this attribute.

      Default:
      {}