public void removeAll(Iterable<Bean<?>> removable) { for (Bean<?> bean : removable) { BeanIdentifier beanIdentifier = contextuals.remove(bean); if (beanIdentifier == null && bean instanceof RIBean) { beanIdentifier = ((RIBean<?>) bean).getIdentifier(); } if (beanIdentifier != null) { contextualsInverse.remove(beanIdentifier); passivationCapableContextuals.remove(beanIdentifier); } } } }
public void removeAll(Iterable<Bean<?>> removable) { for (Bean<?> bean : removable) { BeanIdentifier beanIdentifier = contextuals.remove(bean); if (beanIdentifier == null && bean instanceof RIBean) { beanIdentifier = ((RIBean<?>) bean).getIdentifier(); } if (beanIdentifier != null) { contextualsInverse.remove(beanIdentifier); passivationCapableContextuals.remove(beanIdentifier); } } } }
public void removeAll(Iterable<Bean<?>> removable) { for (Bean<?> bean : removable) { BeanIdentifier beanIdentifier = contextuals.remove(bean); if (beanIdentifier == null && bean instanceof RIBean) { beanIdentifier = ((RIBean<?>) bean).getIdentifier(); } if (beanIdentifier != null) { contextualsInverse.remove(beanIdentifier); passivationCapableContextuals.remove(beanIdentifier); } } } }
public void removeAll(Iterable<Bean<?>> removable) { for (Bean<?> bean : removable) { BeanIdentifier beanIdentifier = contextuals.remove(bean); if (beanIdentifier == null && bean instanceof RIBean) { beanIdentifier = ((RIBean<?>) bean).getIdentifier(); } if (beanIdentifier != null) { contextualsInverse.remove(beanIdentifier); passivationCapableContextuals.remove(beanIdentifier); } } } }
public void removeAll(Iterable<Bean<?>> removable) { for (Bean<?> bean : removable) { BeanIdentifier beanIdentifier = contextuals.remove(bean); if (beanIdentifier == null && bean instanceof RIBean) { beanIdentifier = ((RIBean<?>) bean).getIdentifier(); } if (beanIdentifier != null) { contextualsInverse.remove(beanIdentifier); passivationCapableContextuals.remove(beanIdentifier); } } } }
/** * A slightly optimized way to get the bean identifier - there is not need to call ContextualStore.putIfAbsent() for passivation capable beans because it's * already called during bootstrap. See also {@link BeanManagerImpl#addBean(Bean)}. * * @param contextual * @param contextualStore * @param serviceRegistry * @return the identifier for the given contextual */ private static BeanIdentifier getIdentifier(Contextual<?> contextual, ContextualStore contextualStore, ServiceRegistry serviceRegistry) { if (contextual instanceof RIBean<?>) { return ((RIBean<?>) contextual).getIdentifier(); } if (contextualStore == null) { contextualStore = serviceRegistry.get(ContextualStore.class); } return contextualStore.putIfAbsent(contextual); }
/** * A slightly optimized way to get the bean identifier - there is not need to call ContextualStore.putIfAbsent() for passivation capable beans because it's * already called during bootstrap. See also {@link BeanManagerImpl#addBean(Bean)}. * * @param contextual * @param contextualStore * @param serviceRegistry * @return the identifier for the given contextual */ private static BeanIdentifier getIdentifier(Contextual<?> contextual, ContextualStore contextualStore, ServiceRegistry serviceRegistry) { if (contextual instanceof RIBean<?>) { return ((RIBean<?>) contextual).getIdentifier(); } if (contextualStore == null) { contextualStore = serviceRegistry.get(ContextualStore.class); } return contextualStore.putIfAbsent(contextual); }
/** * A slightly optimized way to get the bean identifier - there is not need to call ContextualStore.putIfAbsent() for passivation capable beans because it's * already called during bootstrap. See also {@link BeanManagerImpl#addBean(Bean)}. * * @param contextual * @param contextualStore * @param serviceRegistry * @return the identifier for the given contextual */ private static BeanIdentifier getIdentifier(Contextual<?> contextual, ContextualStore contextualStore, ServiceRegistry serviceRegistry) { if (contextual instanceof RIBean<?>) { return ((RIBean<?>) contextual).getIdentifier(); } if (contextualStore == null) { contextualStore = serviceRegistry.get(ContextualStore.class); } return contextualStore.putIfAbsent(contextual); }
/** * A slightly optimized way to get the bean identifier - there is not need to call ContextualStore.putIfAbsent() for passivation capable beans because it's * already called during bootstrap. See also {@link BeanManagerImpl#addBean(Bean)}. * * @param contextual * @param contextualStore * @param serviceRegistry * @return the identifier for the given contextual */ private static BeanIdentifier getIdentifier(Contextual<?> contextual, ContextualStore contextualStore, ServiceRegistry serviceRegistry) { if (contextual instanceof RIBean<?>) { return ((RIBean<?>) contextual).getIdentifier(); } if (contextualStore == null) { contextualStore = serviceRegistry.get(ContextualStore.class); } return contextualStore.putIfAbsent(contextual); }
/** * A slightly optimized way to get the bean identifier - there is not need to call ContextualStore.putIfAbsent() for passivation capable beans because it's * already called during bootstrap. See also {@link BeanManagerImpl#addBean(Bean)}. * * @param contextual * @param contextualStore * @param serviceRegistry * @return the identifier for the given contextual */ private static BeanIdentifier getIdentifier(Contextual<?> contextual, ContextualStore contextualStore, ServiceRegistry serviceRegistry) { if (contextual instanceof RIBean<?>) { return ((RIBean<?>) contextual).getIdentifier(); } if (contextualStore == null) { contextualStore = serviceRegistry.get(ContextualStore.class); } return contextualStore.putIfAbsent(contextual); }
/** * A slightly optimized way to get the bean identifier - there is not need to call ContextualStore.putIfAbsent() for passivation capable beans because it's * already called during bootstrap. See also {@link BeanManagerImpl#addBean(Bean)}. * * @param contextual * @param contextualStore * @param serviceRegistry * @return the identifier for the given contextual */ private static BeanIdentifier getIdentifier(Contextual<?> contextual, ContextualStore contextualStore, ServiceRegistry serviceRegistry) { if (contextual instanceof RIBean<?>) { return ((RIBean<?>) contextual).getIdentifier(); } if (contextualStore == null) { contextualStore = serviceRegistry.get(ContextualStore.class); } return contextualStore.putIfAbsent(contextual); }