Examples of IBeanAlias


Examples of org.springframework.ide.eclipse.beans.core.model.IBeanAlias

  @Override
  protected boolean doesMatch(IModelElement element, Pattern pattern,
      IProgressMonitor monitor) {
    if (element instanceof IBeanAlias) {
      IBeanAlias alias = (IBeanAlias) element;
      if (pattern.matcher(alias.getBeanName()).matches()) {
        return true;
      }
    }
    else if (element instanceof IBean) {
      IBean bean = (IBean) element;
View Full Code Here

Examples of org.springframework.ide.eclipse.beans.core.model.IBeanAlias

    if (aliasNode != null) {
      alias = aliasNode.getNodeValue();
    }

    AliasDefinition definition = new AliasDefinition(beanName, alias);
    IBeanAlias beanAlias = null;

    if (alias != null) {
      beanAlias = config.getAlias(alias);
    }
View Full Code Here

Examples of org.springframework.ide.eclipse.beans.core.model.IBeanAlias

  public static IBean getBean(String name, IModelElement context) {
    if (context instanceof IBeansConfig) {
      IBeansConfig config = (IBeansConfig) context;
      IBean bean = config.getBean(name);
      if (bean == null) {
        IBeanAlias alias = config.getAlias(name);
        if (alias != null) {
          bean = config.getBean(alias.getBeanName());
        }
      }
      if (bean == null) {
        for (IBeansComponent component : config.getComponents()) {
          bean = getBean(name, component);
          if (bean != null) {
            return bean;
          }
        }
      }
      return bean;
    }
    else if (context instanceof IBeansConfigSet) {
      IBeansConfigSet configSet = (IBeansConfigSet) context;
      IBean bean = configSet.getBean(name);
      if (bean == null) {
        IBeanAlias alias = configSet.getAlias(name);
        if (alias != null) {
          bean = configSet.getBean(alias.getBeanName());
        }
      }
      if (bean == null) {
        for (IBeansComponent component : configSet.getComponents()) {
          bean = getBean(name, component);
View Full Code Here

Examples of org.springframework.ide.eclipse.beans.core.model.IBeanAlias

   */
  public IBeanAlias getAlias(String name) {
    if (name != null) {
      try {
        r.lock();
        IBeanAlias alias = aliases.get(name);
        if (alias != null) {
          return alias;
        }

        for (IBeansImport beansImport : imports) {
View Full Code Here

Examples of org.springframework.ide.eclipse.beans.core.model.IBeanAlias

    if (selection.size() == 1) {
      Object element = selection.getFirstElement();
      String beanName = null;
      IBeansConfig config = null;
      if (element instanceof IBeanAlias) {
        IBeanAlias alias = (IBeanAlias) element;
        beanName = alias.getBeanName();
        config = BeansModelUtils.getConfig(alias);
      }
      else if (element instanceof IBeanReference) {
        IBeanReference reference = (IBeanReference) element;
        beanName = reference.getBeanName();
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.