Examples of StrutsConstantManager


Examples of com.intellij.struts2.model.constant.StrutsConstantManager

    final String paramName = initParamElement.getParamName().getStringValue();
    if (StringUtil.isEmpty(paramName)) {
      return null;
    }

    final StrutsConstantManager constantManager = StrutsConstantManager.getInstance(myElement.getProject());

    @SuppressWarnings({"ConstantConditions"})
    final Converter converter = constantManager.findConverter(myElement, StrutsConstantKey.create(paramName));
    if (converter == null) {
      return null;
    }

    return Pair.create(paramValueElement, converter);
View Full Code Here

Examples of com.intellij.struts2.model.constant.StrutsConstantManager

      final Module module = ModuleUtilCore.findModuleForPsiElement(myElement);
      if (module == null) {
        return ArrayUtil.EMPTY_OBJECT_ARRAY;
      }

      final StrutsConstantManager constantManager = StrutsConstantManager.getInstance(myElement.getProject());
      final List<StrutsConstant> constants = constantManager.getConstants(module);

      return ContainerUtil.map2Array(constants, new Function<StrutsConstant, Object>() {
        public Object fun(final StrutsConstant strutsConstant) {
          return strutsConstant.getName();
        }
View Full Code Here

Examples of com.intellij.struts2.model.constant.StrutsConstantManager

    final Module module = context.getModule();
    if (module == null) {
      return Collections.emptyList();
    }

    final StrutsConstantManager constantManager = StrutsConstantManager.getInstance(module.getProject());
    return ContainerUtil.map(constantManager.getConstants(module), CONSTANT_NAME_FUNCTION);
  }
View Full Code Here

Examples of com.intellij.struts2.model.constant.StrutsConstantManager

    if (StringUtil.isEmpty(constantName)) {
      return null;
    }

    final XmlTag xmlTag = domElement.getXmlTag();
    final StrutsConstantManager constantManager = StrutsConstantManager.getInstance(xmlTag.getProject());

    //noinspection ConstantConditions
    return constantManager.findConverter(xmlTag, StrutsConstantKey.<Object>create(constantName));
  }
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.