Interface BeanManager

All Known Implementing Classes:
LifecycleManager, PlexusLifecycleManager

public interface BeanManager
Service that manages the lifecycle of beans.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    manage(Class<?> clazz)
    Decides whether instances of the given bean type should be reported to this manager.
    boolean
    manage(Object bean)
    Asks this manager to manage the given bean instance.
    manage(BeanProperty<?> property)
    Asks this manager to manage the given bean property.
    boolean
    Asks this manager to unmanage all the bean instances it knows about.
    boolean
    Asks this manager to unmanage the given bean instance.
  • Method Details

    • manage

      boolean manage(Class<?> clazz)
      Decides whether instances of the given bean type should be reported to this manager.
      Parameters:
      clazz - The bean type
      Returns:
      true if instances of the bean should be reported; otherwise false
    • manage

      PropertyBinding manage(BeanProperty<?> property)
      Asks this manager to manage the given bean property.
      Parameters:
      property - The bean property
      Returns:
      Non-null binding if the bean property was managed; otherwise null
    • manage

      boolean manage(Object bean)
      Asks this manager to manage the given bean instance.
      Parameters:
      bean - The bean instance
      Returns:
      true if the bean instance was managed; otherwise false
    • unmanage

      boolean unmanage(Object bean)
      Asks this manager to unmanage the given bean instance.
      Parameters:
      bean - The bean instance
      Returns:
      true if the bean instance was unmanaged; otherwise false
    • unmanage

      boolean unmanage()
      Asks this manager to unmanage all the bean instances it knows about.
      Returns:
      true if any bean instances were unmanaged; otherwise false