Java 类com.intellij.psi.tree.CustomParsingType 实例源码

项目:RtplPlugin    文件:XmlParsing.java   
public void parseTagContent() {
  PsiBuilder.Marker xmlText = null;
  while (token() != XML_END_TAG_START && !eof()) {
    final IElementType tt = token();
    if (tt == XML_START_TAG_START) {
      xmlText = terminateText(xmlText);
      parseTag(false);
    }
    else if (tt == XML_ENTITY_REF_TOKEN) {
      xmlText = terminateText(xmlText);
      parseReference();
    }
    else if (tt == XML_CHAR_ENTITY_REF) {
      xmlText = startText(xmlText);
      parseReference();
    }
    else if (isCommentToken(tt)) {
      xmlText = terminateText(xmlText);
      parseComment();
    }
    else if (tt == XML_BAD_CHARACTER) {
      xmlText = startText(xmlText);
      final PsiBuilder.Marker error = mark();
      advance();
      error.error(XmlErrorMessages.message("unescaped.ampersand.or.nonterminated.character.entity.reference"));
    }
    else if (tt instanceof CustomParsingType || tt instanceof ILazyParseableElementType) {
      xmlText = terminateText(xmlText);
      advance();
    }
    else {
      xmlText = startText(xmlText);
      advance();
    }
  }

  terminateText(xmlText);
}
项目:consulo-csharp    文件:CSharpDocParsing.java   
public void parseTagContent()
{
    PsiBuilder.Marker xmlText = null;
    while(token() != CSharpDocTokenType.XML_END_TAG_START && !eof())
    {
        final IElementType tt = token();
        if(tt == CSharpDocTokenType.XML_START_TAG_START)
        {
            xmlText = terminateText(xmlText);
            parseTag();
        }
        else if(isCommentToken(tt))
        {
            xmlText = terminateText(xmlText);
            parseComment();
        }
        else if(tt instanceof CustomParsingType || tt instanceof ILazyParseableElementType)
        {
            xmlText = terminateText(xmlText);
            advance();
        }
        else
        {
            xmlText = startText(xmlText);
            advance();
        }
    }

    terminateText(xmlText);
}
项目:intellij-ce-playground    文件:XmlParsing.java   
public void parseTagContent() {
  PsiBuilder.Marker xmlText = null;
  while (token() != XML_END_TAG_START && !eof()) {
    final IElementType tt = token();
    if (tt == XML_START_TAG_START) {
      xmlText = terminateText(xmlText);
      parseTag(false);
    }
    else if (tt == XML_PI_START) {
      xmlText = terminateText(xmlText);
      parseProcessingInstruction();
    }
    else if (tt == XML_ENTITY_REF_TOKEN) {
      xmlText = terminateText(xmlText);
      parseReference();
    }
    else if (tt == XML_CHAR_ENTITY_REF) {
      xmlText = startText(xmlText);
      parseReference();
    }
    else if (tt == XML_CDATA_START) {
      xmlText = startText(xmlText);
      parseCData();
    }
    else if (isCommentToken(tt)) {
      xmlText = terminateText(xmlText);
      parseComment();
    }
    else if (tt == XML_BAD_CHARACTER) {
      xmlText = startText(xmlText);
      final PsiBuilder.Marker error = mark();
      advance();
      error.error(XmlErrorMessages.message("unescaped.ampersand.or.nonterminated.character.entity.reference"));
    }
    else if (tt instanceof CustomParsingType || tt instanceof ILazyParseableElementType) {
      xmlText = terminateText(xmlText);
      advance();
    }
    else {
      xmlText = startText(xmlText);
      advance();
    }
  }

  terminateText(xmlText);
}
项目:tools-idea    文件:XmlParsing.java   
public void parseTagContent() {
  PsiBuilder.Marker xmlText = null;
  while (token() != XML_END_TAG_START && !eof()) {
    final IElementType tt = token();
    if (tt == XML_START_TAG_START) {
      xmlText = terminateText(xmlText);
      parseTag(false);
    }
    else if (tt == XML_PI_START) {
      xmlText = terminateText(xmlText);
      parseProcessingInstruction();
    }
    else if (tt == XML_ENTITY_REF_TOKEN) {
      xmlText = terminateText(xmlText);
      parseReference();
    }
    else if (tt == XML_CHAR_ENTITY_REF) {
      xmlText = startText(xmlText);
      parseReference();
    }
    else if (tt == XML_CDATA_START) {
      xmlText = startText(xmlText);
      parseCData();
    }
    else if (isCommentToken(tt)) {
      xmlText = terminateText(xmlText);
      parseComment();
    }
    else if (tt == XML_BAD_CHARACTER) {
      xmlText = startText(xmlText);
      final PsiBuilder.Marker error = mark();
      advance();
      error.error(XmlErrorMessages.message("unescaped.ampersand.or.nonterminated.character.entity.reference"));
    }
    else if (tt instanceof CustomParsingType || tt instanceof ILazyParseableElementType) {
      xmlText = terminateText(xmlText);
      advance();
    }
    else {
      xmlText = startText(xmlText);
      advance();
    }
  }

  terminateText(xmlText);
}
项目:consulo-xml    文件:XmlParsing.java   
public void parseTagContent() {
  PsiBuilder.Marker xmlText = null;
  while (token() != XML_END_TAG_START && !eof()) {
    final IElementType tt = token();
    if (tt == XML_START_TAG_START) {
      xmlText = terminateText(xmlText);
      parseTag(false);
    }
    else if (tt == XML_PI_START) {
      xmlText = terminateText(xmlText);
      parseProcessingInstruction();
    }
    else if (tt == XML_ENTITY_REF_TOKEN) {
      xmlText = terminateText(xmlText);
      parseReference();
    }
    else if (tt == XML_CHAR_ENTITY_REF) {
      xmlText = startText(xmlText);
      parseReference();
    }
    else if (tt == XML_CDATA_START) {
      xmlText = startText(xmlText);
      parseCData();
    }
    else if (isCommentToken(tt)) {
      xmlText = terminateText(xmlText);
      parseComment();
    }
    else if (tt == XML_BAD_CHARACTER) {
      xmlText = startText(xmlText);
      final PsiBuilder.Marker error = mark();
      advance();
      error.error(XmlErrorMessages.message("unescaped.ampersand.or.nonterminated.character.entity.reference"));
    }
    else if (tt instanceof CustomParsingType || tt instanceof ILazyParseableElementType) {
      xmlText = terminateText(xmlText);
      advance();
    }
    else {
      xmlText = startText(xmlText);
      advance();
    }
  }

  terminateText(xmlText);
}