當前位置: 首頁>>代碼示例>>Java>>正文


Java WordsScanner類代碼示例

本文整理匯總了Java中com.intellij.lang.cacheBuilder.WordsScanner的典型用法代碼示例。如果您正苦於以下問題:Java WordsScanner類的具體用法?Java WordsScanner怎麽用?Java WordsScanner使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


WordsScanner類屬於com.intellij.lang.cacheBuilder包,在下文中一共展示了WordsScanner類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: getWordsScanner

import com.intellij.lang.cacheBuilder.WordsScanner; //導入依賴的package包/類
@Nullable
@Override
public WordsScanner getWordsScanner() {
    /**
     * Creates a new instance of the words scanner.
     *
     * @param lexer              the lexer used for breaking the text into tokens.
     * @param identifierTokenSet the set of token types which represent identifiers.
     * @param commentTokenSet    the set of token types which represent comments.
     * @param literalTokenSet    the set of token types which represent literals.
     * @param skipCodeContextTokenSet the set of token types which should not be considered as code context.
     */

    DefaultWordsScanner wordsScanner = new DefaultWordsScanner(new MultiMarkdownLexer(),
            TokenSet.create(WIKI_LINK_REF, WIKI_LINK_TEXT),
            TokenSet.create(COMMENT),
            TokenSet.EMPTY,
            TokenSet.EMPTY) {
        @Override
        public int getVersion() {
            return super.getVersion() + 7;
        }
    };

    return wordsScanner;
}
 
開發者ID:vsch,項目名稱:idea-multimarkdown,代碼行數:27,代碼來源:MultiMarkdownFindUsagesProvider.java

示例2: getWordsScanner

import com.intellij.lang.cacheBuilder.WordsScanner; //導入依賴的package包/類
@Nullable
	@Override
	public WordsScanner getWordsScanner() {
		return null; // seems ok as JavaFindUsagesProvider does same thing
//		System.out.println("getWordsScanner()");
//		final ANTLRv4Lexer lexer = new ANTLRv4Lexer(null);
//
//		LexerATNSimulator sim =
//			ANTLRUtils.getLexerATNSimulator(lexer, ANTLRv4Lexer._ATN, lexer.getInterpreter().decisionToDFA,
//											lexer.getInterpreter().getSharedContextCache());
//		lexer.setInterpreter(sim);
//		WordsScanner scanner =
//			new DefaultWordsScanner(new LexerAdaptor(lexer),
//									TokenSet.create(ANTLRv4TokenTypes.RULE_REF,
//													ANTLRv4TokenTypes.TOKEN_REF),
//									ANTLRv4TokenTypes.COMMENTS,
//									TokenSet.create(ANTLRv4TokenTypes.STRING_LITERAL)
//			);
//		return scanner;
	}
 
開發者ID:antlr,項目名稱:intellij-plugin-v4,代碼行數:21,代碼來源:ANTLRv4FindUsagesProvider.java

示例3: getWordsScanner

import com.intellij.lang.cacheBuilder.WordsScanner; //導入依賴的package包/類
@Nullable
@Override
public WordsScanner getWordsScanner() {
    return new DefaultWordsScanner(new FrogLexer(),
            TokenSet.create(FrogTypes.FROG_WORD),
            FrogParserDefinition.COMMENT_TOKENS,
            TokenSet.create(
                    FrogTypes.FROG_NULL,
                    FrogTypes.FROG_SIMPLE_STRING,
                    FrogTypes.FROG_MULTILINE_STRING,
                    FrogTypes.FROG_INTEGER,
                    FrogTypes.FROG_LONG,
                    FrogTypes.FROG_FLOAT,
                    FrogTypes.FROG_DOUBLE,
                    FrogTypes.FROG_TRUE,
                    FrogTypes.FROG_FALSE,
                    FrogTypes.FROG_BYTE_ARRAY
            ));
}
 
開發者ID:Ladicek,項目名稱:IntelliFrog,代碼行數:20,代碼來源:FrogFindUsagesProvider.java

示例4: getWordsScanner

import com.intellij.lang.cacheBuilder.WordsScanner; //導入依賴的package包/類
@Nullable
@Override
public WordsScanner getWordsScanner() {
    return new DefaultWordsScanner(
            new TSLexerAdapter(),
            TokenSet.create(TSTypes.ID),
            TokenSet.create(TSTypes.COMMENT),
            TokenSet.EMPTY
    );
}
 
開發者ID:CouleeApps,項目名稱:TS-IJ,代碼行數:11,代碼來源:TSFindUsagesProvider.java

示例5: getWordsScanner

import com.intellij.lang.cacheBuilder.WordsScanner; //導入依賴的package包/類
@Nullable
@Override
public WordsScanner getWordsScanner() {
  return new DefaultWordsScanner(new AppleScriptLexerAdapter(),
          TokenSet.create(AppleScriptTypes.IDENTIFIER),
          TokenSet.create(AppleScriptTypes.COMMENT),
          TokenSet.create(AppleScriptTypes.STRING_LITERAL));
}
 
開發者ID:ant-druha,項目名稱:AppleScript-IDEA,代碼行數:9,代碼來源:AppleScriptFindUsagesProvider.java

示例6: getWordsScanner

import com.intellij.lang.cacheBuilder.WordsScanner; //導入依賴的package包/類
@Nullable
@Override
public WordsScanner getWordsScanner() {
  return new DefaultWordsScanner(
      new SoyLexer(),
      TokenSet.create(SoyTypes.IDENTIFIER_WORD),
      TokenSet.create(SoyTypes.COMMENT_BLOCK),
      TokenSet.EMPTY);
}
 
開發者ID:google,項目名稱:bamboo-soy,代碼行數:10,代碼來源:SoyFindUsagesProvider.java

示例7: getWordsScanner

import com.intellij.lang.cacheBuilder.WordsScanner; //導入依賴的package包/類
@Nullable
@Override
public WordsScanner getWordsScanner() {
    return new DefaultWordsScanner(
        new ImpexLexerAdapter(),
        orSet(
            create(ImpexTypes.MACRO_NAME_DECLARATION),
            create(ImpexTypes.MACRO_DECLARATION),
            create(ImpexTypes.MACRO_USAGE)
        ),
        create(ImpexTypes.COMMENT),
        TokenSet.ANY
    );
}
 
開發者ID:AlexanderBartash,項目名稱:hybris-integration-intellij-idea-plugin,代碼行數:15,代碼來源:ImpexFindUsagesProvider.java

示例8: getWordsScanner

import com.intellij.lang.cacheBuilder.WordsScanner; //導入依賴的package包/類
@Nullable
@Override
public WordsScanner getWordsScanner() {
    return new DefaultWordsScanner(new YAMLFlexLexer(),
            TokenSet.create(YAMLTokenTypes.SCALAR_KEY),
            TokenSet.create(YAMLTokenTypes.COMMENT),
            TokenSet.create(YAMLTokenTypes.SCALAR_TEXT, YAMLTokenTypes.SCALAR_DSTRING, YAMLTokenTypes.SCALAR_STRING));
}
 
開發者ID:seedstack,項目名稱:intellij-plugin,代碼行數:9,代碼來源:CoffigFindUsagesProvider.java

示例9: getWordsScanner

import com.intellij.lang.cacheBuilder.WordsScanner; //導入依賴的package包/類
@NotNull
public WordsScanner getWordsScanner() {
    return  new DefaultWordsScanner(new LuaLexer(),
        LuaTokenTypes.IDENTIFIERS_SET, LuaTokenTypes.COMMENT_SET, LuaTokenTypes.LITERALS_SET) {{
        setMayHaveFileRefsInLiterals(true);
    }};
}
 
開發者ID:internetisalie,項目名稱:lua-for-idea,代碼行數:8,代碼來源:LuaFindUsagesProvider.java

示例10: getWordsScanner

import com.intellij.lang.cacheBuilder.WordsScanner; //導入依賴的package包/類
@Nullable
@Override
public WordsScanner getWordsScanner() {
	return new DefaultWordsScanner(
			new SQFLexerAdapter(),
			SQFParserDefinition.IDENTIFIERS,
			SQFParserDefinition.COMMENTS,
			SQFParserDefinition.NUMBER_LITERALS
	);
}
 
開發者ID:kayler-renslow,項目名稱:arma-intellij-plugin,代碼行數:11,代碼來源:SQFFindUsagesProvider.java

示例11: getWordsScanner

import com.intellij.lang.cacheBuilder.WordsScanner; //導入依賴的package包/類
@Nullable
@Override
public WordsScanner getWordsScanner() {

    return new DefaultWordsScanner(new ProtoLexerAdapter(),
            ProtoParserDefinition.IDENTIFIER_TOKEN_SET,
            ProtoParserDefinition.COMMENT_TOKEN_SET,
            ProtoParserDefinition.LITERAL_TOKEN_SET);
}
 
開發者ID:protostuff,項目名稱:protobuf-jetbrains-plugin,代碼行數:10,代碼來源:ProtoFindUsagesProvider.java

示例12: getWordsScanner

import com.intellij.lang.cacheBuilder.WordsScanner; //導入依賴的package包/類
@Override
public WordsScanner getWordsScanner() {
  return new DefaultWordsScanner(
      new BuildLexer(LexerMode.SyntaxHighlighting),
      tokenSet(TokenKind.IDENTIFIER),
      tokenSet(TokenKind.COMMENT),
      tokenSet(TokenKind.STRING));
}
 
開發者ID:bazelbuild,項目名稱:intellij,代碼行數:9,代碼來源:BuildFindUsagesProvider.java

示例13: getWordsScanner

import com.intellij.lang.cacheBuilder.WordsScanner; //導入依賴的package包/類
@Nullable
@Override
public WordsScanner getWordsScanner() {
  return new DefaultWordsScanner(SchemaFlexAdapter.newInstance(),
      SchemaParserDefinition.IDENTIFIERS,
      SchemaParserDefinition.COMMENTS,
      SchemaParserDefinition.LITERALS);
}
 
開發者ID:SumoLogic,項目名稱:epigraph,代碼行數:9,代碼來源:SchemaFindUsagesProvider.java

示例14: getWordsScanner

import com.intellij.lang.cacheBuilder.WordsScanner; //導入依賴的package包/類
@Nullable
    @Override
    public WordsScanner getWordsScanner() {
        return new DefaultWordsScanner(
                new CndLexerAdapter(),
//                TokenSet.EMPTY,
                TokenSet.create(CndTypes.NAMESPACE_NAME, CndTypes.NODE_TYPE_NAME, CndTypes.PROPERTY_NAME),
                TokenSet.create(CndTypes.COMMENT),
                TokenSet.EMPTY
                );
    }
 
開發者ID:Tolc,項目名稱:IntelliJ_Jahia_plugin,代碼行數:12,代碼來源:CndFindUsagesProvider.java

示例15: getWordsScanner

import com.intellij.lang.cacheBuilder.WordsScanner; //導入依賴的package包/類
@Nullable
@Override
public WordsScanner getWordsScanner() {
  return new DefaultWordsScanner(new KLexerAdapter(),
      TokenSet.create(KTypes.USER_ID),
      TokenSet.EMPTY,
      TokenSet.EMPTY);
}
 
開發者ID:a2ndrade,項目名稱:k-intellij-plugin,代碼行數:9,代碼來源:KFindUsagesProvider.java


注:本文中的com.intellij.lang.cacheBuilder.WordsScanner類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。