类 BeanNotOfRequiredTypeException

    • 构造器详细资料

      • BeanNotOfRequiredTypeException

        public BeanNotOfRequiredTypeException​(String beanName,
                                              Class<?> requiredType,
                                              Class<?> actualType)
        Create a new BeanNotOfRequiredTypeException.
        参数:
        beanName - the name of the bean requested
        requiredType - the required type
        actualType - the actual type returned, which did not match the expected type
    • 方法详细资料

      • getBeanName

        public String getBeanName()
        Return the name of the instance that was of the wrong type.
      • getActualType

        public Class<?> getActualType()
        Return the actual type of the instance found.