Package jodd.petite

Examples of jodd.petite.BeanData


    }
  };

  public Object lookup(String name) {
    Map<String, BeanData> threadLocalMap = context.get();
    BeanData beanData = threadLocalMap.get(name);
    if (beanData == null) {
      return null;
    }
    return beanData.getBean();
  }
View Full Code Here


    }
    return beanData.getBean();
  }

  public void register(BeanDefinition beanDefinition, Object bean) {
    BeanData beanData = new BeanData(beanDefinition, bean);
    Map<String, BeanData> threadLocalMap = context.get();
    threadLocalMap.put(beanDefinition.getName(), beanData);
  }
View Full Code Here

public class SingletonScope implements Scope {

  protected Map<String, BeanData> instances = new HashMap<String, BeanData>();

  public Object lookup(String name) {
    BeanData beanData = instances.get(name);
    if (beanData == null) {
      return null;
    }
    return beanData.getBean();
  }
View Full Code Here

    }
    return beanData.getBean();
  }

  public void register(BeanDefinition beanDefinition, Object bean) {
    BeanData beanData = new BeanData(beanDefinition, bean);
    instances.put(beanDefinition.getName(), beanData);
  }
View Full Code Here

    Map<String, BeanData> map = getRequestMap(servletRequest);
    if (map == null) {
      return null;
    }

    BeanData beanData = map.get(name);
    if (beanData == null) {
      return null;
    }
    return beanData.getBean();
  }
View Full Code Here

    Map<String, BeanData> map = getRequestMap(servletRequest);
    if (map == null) {
      map = createRequestMap(servletRequest);
    }

    BeanData beanData = new BeanData(beanDefinition, bean);
    map.put(beanDefinition.getName(), beanData);
  }
View Full Code Here

    Map<String, BeanData> map = getSessionMap(session);
    if (map == null) {
      return null;
    }

    BeanData beanData = map.get(name);
    if (beanData == null) {
      return null;
    }
    return beanData.getBean();
  }
View Full Code Here

    Map<String, BeanData> map = getSessionMap(session);
    if (map == null) {
      map = registerSessionBeans(session);
    }

    BeanData beanData = new BeanData(beanDefinition, bean);
    map.put(beanDefinition.getName(), beanData);

    registerDestroyableBeans(beanData);
  }
View Full Code Here

TOP

Related Classes of jodd.petite.BeanData

Copyright © 2018 www.massapicom. 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.