当前位置: 首页>>代码示例>>Java>>正文


Java LightParameterListBuilder类代码示例

本文整理汇总了Java中com.intellij.psi.impl.light.LightParameterListBuilder的典型用法代码示例。如果您正苦于以下问题:Java LightParameterListBuilder类的具体用法?Java LightParameterListBuilder怎么用?Java LightParameterListBuilder使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


LightParameterListBuilder类属于com.intellij.psi.impl.light包,在下文中一共展示了LightParameterListBuilder类的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: ManLightMethodBuilderImpl

import com.intellij.psi.impl.light.LightParameterListBuilder; //导入依赖的package包/类
public ManLightMethodBuilderImpl( PsiManager manager, String name )
{
  super( manager, JavaLanguage.INSTANCE, name,
         new LightParameterListBuilder( manager, JavaLanguage.INSTANCE ), new ManLightModifierListImpl( manager, JavaLanguage.INSTANCE ) );
  _nameIdentifier = new LightIdentifier( manager, name );
}
 
开发者ID:manifold-systems,项目名称:manifold-ij,代码行数:7,代码来源:ManLightMethodBuilderImpl.java

示例2: GrAccessorMethodImpl

import com.intellij.psi.impl.light.LightParameterListBuilder; //导入依赖的package包/类
public GrAccessorMethodImpl(@NotNull GrField property, boolean isSetter, String name) {
  super(property.getManager(), GroovyLanguage.INSTANCE, name,
        new LightParameterListBuilder(property.getManager(), GroovyLanguage.INSTANCE),
        new LightModifierList(property.getManager()) {
          @Override
          public String getText() {
            final String[] modifiers = getModifiers();
            if (modifiers.length == 0) return "";
            if (modifiers.length == 1) return modifiers[0];

            return StringUtil.join(modifiers, " ");
          }
        });
  myProperty = property;
  myIsSetter = isSetter;

  if (myIsSetter) {
    PsiType type = myProperty.getDeclaredType();
    if (type == null) {
      type = TypesUtil.getJavaLangObject(myProperty);
    }
    addParameter(myProperty.getName(), type);
  }

  setMethodReturnType(myIsSetter ? PsiType.VOID : myProperty.getType());

  addModifier(PsiModifier.PUBLIC);
  if (myProperty.hasModifierProperty(PsiModifier.STATIC)) {
    addModifier(PsiModifier.STATIC);
  }
  else if (myProperty.hasModifierProperty(PsiModifier.FINAL)) { //don't add final modifier to static method
    addModifier(PsiModifier.FINAL);
  }

  if (GrTraitUtil.isTrait(property.getContainingClass())) {
    addModifier(PsiModifier.ABSTRACT);
  }

  setNavigationElement(property);
  setBaseIcon(JetgroovyIcons.Groovy.Property);

  setContainingClass(myProperty.getContainingClass());
  setMethodKind("AccessorMethod");
  setOriginInfo("synthetic accessor for '"+myProperty.getName()+"'");
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:46,代码来源:GrAccessorMethodImpl.java

示例3: GrAccessorMethodImpl

import com.intellij.psi.impl.light.LightParameterListBuilder; //导入依赖的package包/类
public GrAccessorMethodImpl(@NotNull GrField property, boolean isSetter, String name) {
  super(property.getManager(), GroovyFileType.GROOVY_LANGUAGE, name,
        new LightParameterListBuilder(property.getManager(), GroovyFileType.GROOVY_LANGUAGE),
        new LightModifierList(property.getManager()) {
          @Override
          public String getText() {
            final String[] modifiers = getModifiers();
            if (modifiers.length == 0) return "";
            if (modifiers.length == 1) return modifiers[0];

            return StringUtil.join(modifiers, " ");
          }
        });
  myProperty = property;
  myIsSetter = isSetter;

  if (myIsSetter) {
    PsiType type = myProperty.getDeclaredType();
    if (type == null) {
      type = TypesUtil.getJavaLangObject(myProperty);
    }
    addParameter(myProperty.getName(), type);
  }

  setMethodReturnType(myIsSetter ? PsiType.VOID : myProperty.getType());

  addModifier(PsiModifier.PUBLIC);
  if (myProperty.hasModifierProperty(PsiModifier.STATIC)) {
    addModifier(PsiModifier.STATIC);
  }
  else if (myProperty.hasModifierProperty(PsiModifier.FINAL)) { //don't add final modifier to static method
    addModifier(PsiModifier.FINAL);
  }

  setNavigationElement(property);
  setBaseIcon(JetgroovyIcons.Groovy.Property);

  setContainingClass(myProperty.getContainingClass());
  setMethodKind("AccessorMethod");
  setOriginInfo("synthetic accessor for '"+myProperty.getName()+"'");
}
 
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:42,代码来源:GrAccessorMethodImpl.java

示例4: getParameterList

import com.intellij.psi.impl.light.LightParameterListBuilder; //导入依赖的package包/类
@NotNull
@Override
public PsiParameterList getParameterList()
{
	return new LightParameterListBuilder(PsiManager.getInstance(getProject()), getLanguage());
}
 
开发者ID:consulo,项目名称:consulo-javaee,代码行数:7,代码来源:JspHolderMethodImpl.java


注:本文中的com.intellij.psi.impl.light.LightParameterListBuilder类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。