Interface LocalBeanFactory

  • All Known Implementing Classes:
    AbstractLocalBeanFactory, AdminBeanFactory, AppBeanFactory, WebBeanFactory

    public interface LocalBeanFactory
    The LocalBeanFactory interface specifies the contract that a package-level bean factory must implement--most importantly, the ability to create a bean based on its type name. The BeanFactory class will delegate to a package-level factory if one is specified in a given <bean-package> node in beanFactoryConfig.xml. For more information, see the BeanFactory documentation.
    MicroStrategy Web 9.0.0
    • Method Detail

      • newBean

        WebComponent newBean​(java.lang.String beanName)
                      throws BeanNotFoundException
        Create a bean based on the bean type name.
        beanName - The type name of the desired bean (ex: "ReportBean").
        A new WebComponent instance that corresponds to beanName.
        BeanNotFoundException - If beanName could not be resolved to a class (i.e. it is not supported by this factory).
      • canCreateBean

        boolean canCreateBean​(java.lang.String beanName)
        Check whether this factory can create a bean with a given type name. If this method returns false for a given bean type name, then calling newBean(java.lang.String) with that bean type name will result in a BeanNotFoundException.
        beanName - The type name of the bean to check.
        true if this factory can create a bean for beanName; false otherwise.