Examples of DIContainerException


Examples of org.tamacat.di.DIContainerException

          reader.setErrorHandler(this);
          //reader.setFeature("http://xml.org/sax/features/validation",true);
          //reader.setFeature("http://xml.org/sax/features/namespaces",true);
            reader.parse(new InputSource(IOUtils.getInputStream(xml, getClassLoader())));
        } catch (Exception e) {
            throw new DIContainerException(e);
        }
        return beans;
    }
View Full Code Here

Examples of org.tamacat.di.DIContainerException

     */
    @SuppressWarnings({ "unchecked", "rawtypes" })
  synchronized <T> T getBean(String id, Class<T> type) {
        BeanDefine def = defines.get(id);
        if (def == null) {
            throw new DIContainerException("Error: [" + id + "] is not found in BeanDefines.");
        }

        //singleton instance
        if (def.isSingleton()) {
            //instance is null then create new instance.
View Full Code Here

Examples of org.tamacat.di.DIContainerException

    private T createPrototype() {
        T o = null;
        if (name != null) {
            T obj = DI.configure(xml).getBean(name, type);
            if (obj == null) {
              throw new DIContainerException(name + " is not found.[" + xml + "]");
            }
        }
        if (o == null && type != null) {
            o = ClassUtils.newInstance(type);
        }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.