Class ContextualReloadHelper


  • public class ContextualReloadHelper
    extends Object
    The Class ContextualReloadHelper.
    Author:
    alpapad@gmail.com
    • Constructor Detail

      • ContextualReloadHelper

        public ContextualReloadHelper()
    • Method Detail

      • addToReloadSet

        public static boolean addToReloadSet​(javax.enterprise.context.spi.Context ctx,
                                             javax.enterprise.context.spi.Contextual<Object> managedBean)
        Tries to add the bean in the context so it is reloaded in the next activation of the context.
        Parameters:
        ctx -
        managedBean -
        Returns:
      • destroy

        public static void destroy​(WeldHotswapContext ctx,
                                   javax.enterprise.context.spi.Contextual<?> managedBean)
        Will remove bean from context forcing a clean new instance to be created (eg calling post-construct)
        Parameters:
        ctx -
        managedBean -
      • reinitialize

        public static void reinitialize​(javax.enterprise.context.spi.Context ctx,
                                        javax.enterprise.context.spi.Contextual<Object> contextual)
        Will re-inject any managed beans in the target. Will not call any other life-cycle methods
        Parameters:
        ctx -
        managedBean -