Java 类com.intellij.psi.impl.source.tree.PsiCommentImpl 实例源码

项目:codehelper.generator    文件:OnePojoInfoHelper.java   
private static String parseComment(PsiField field) {
    if(field == null){
        return StringUtils.EMPTY;
    }
    PsiElement[] children = field.getChildren();
    for (PsiElement child : children) {
        String text = child.getText();
        if(child instanceof PsiDocCommentImpl || child instanceof PsiCommentImpl){
            return formatText(text);
        }
    }
    return StringUtils.EMPTY;
}
项目:intellij-haxe    文件:HaxeAstFactory.java   
@Nullable
@Override
public LeafElement createLeaf(IElementType type, CharSequence text) {
  if (HaxeTokenTypeSets.COMMENTS.contains(type)) {
    return new PsiCommentImpl(type, text);
  }

  return new HaxePsiTokenImpl(type, text);
}
项目:consulo-java    文件:JavaASTLeafFactory.java   
@Override
@NotNull
public LeafElement createLeaf(@NotNull final IElementType type, @NotNull LanguageVersion languageVersion, @NotNull final CharSequence text)
{
    if(type == C_STYLE_COMMENT || type == END_OF_LINE_COMMENT)
    {
        return new PsiCommentImpl(type, text);
    }

    return super.createLeaf(type, languageVersion, text);
}
项目:intellij-ce-playground    文件:CommentLiteralEscaper.java   
public CommentLiteralEscaper(PsiCommentImpl host) {
  super(host);
}
项目:intellij-ce-playground    文件:DefaultASTFactoryImpl.java   
@NotNull
@Override
public LeafElement createComment(@NotNull IElementType type, @NotNull CharSequence text) {
  return new PsiCommentImpl(type, text);
}
项目:tools-idea    文件:DefaultASTFactoryImpl.java   
@Override
public LeafElement createComment(IElementType type, CharSequence text) {
  return new PsiCommentImpl(type, text);
}
项目:tools-idea    文件:CommentLiteralEscaper.java   
public CommentLiteralEscaper(PsiCommentImpl host) {
  super(host);
}
项目:consulo    文件:CommentLiteralEscaper.java   
public CommentLiteralEscaper(PsiCommentImpl host) {
  super(host);
}