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


Java AntlrTokenDefProvider类代码示例

本文整理汇总了Java中org.eclipse.xtext.parser.antlr.AntlrTokenDefProvider的典型用法代码示例。如果您正苦于以下问题:Java AntlrTokenDefProvider类的具体用法?Java AntlrTokenDefProvider怎么用?Java AntlrTokenDefProvider使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


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

示例1: getGuiceBindingsUi

import org.eclipse.xtext.parser.antlr.AntlrTokenDefProvider; //导入依赖的package包/类
@Override
public Set<Binding> getGuiceBindingsUi(Grammar grammar) {
	return new BindFactory()
		.addTypeToType("org.eclipse.xtext.ui.editor.contentassist.IProposalConflictHelper", "org.eclipse.xtext.ui.editor.contentassist.antlr.AntlrProposalConflictHelper")
		.addConfiguredBinding("HighlightingLexer",
				"binder.bind(" + Lexer.class.getName() + ".class)"+
				".annotatedWith(com.google.inject.name.Names.named(" +
				"org.eclipse.xtext.ui.LexerUIBindings.HIGHLIGHTING" +
				")).to(" + getFragmentHelper().getLexerClassName(grammar) +".class)")
		.addConfiguredBinding("HighlightingTokenDefProvider",
				"binder.bind(" + ITokenDefProvider.class.getName() + ".class)"+
				".annotatedWith(com.google.inject.name.Names.named(" +
				"org.eclipse.xtext.ui.LexerUIBindings.HIGHLIGHTING" +
				")).to(" + AntlrTokenDefProvider.class.getName() +".class)")
		.getBindings();
}
 
开发者ID:eclipse,项目名称:xtext-extras,代码行数:17,代码来源:AntlrGeneratorFragment.java

示例2: getGuiceBindingsUi

import org.eclipse.xtext.parser.antlr.AntlrTokenDefProvider; //导入依赖的package包/类
@Override
public Set<Binding> getGuiceBindingsUi(Grammar grammar) {
	BindFactory binder = new BindFactory();
		binder.addTypeToType("org.eclipse.xtext.ui.editor.contentassist.IProposalConflictHelper", "org.eclipse.xtext.ui.editor.contentassist.antlr.AntlrProposalConflictHelper");
		if(getNaming().hasIde()){
			binder.addConfiguredBinding("HighlightingLexer",
					"binder.bind(" + Lexer.class.getName() + ".class)"+
					".annotatedWith(com.google.inject.name.Names.named(" +
					"org.eclipse.xtext.ide.LexerIdeBindings.HIGHLIGHTING" +
					")).to(" + getLexerClassName(grammar, getNaming()) +".class)")
				   .addConfiguredBinding("HighlightingTokenDefProvider",
					"binder.bind(" + ITokenDefProvider.class.getName() + ".class)"+
					".annotatedWith(com.google.inject.name.Names.named(" +
					"org.eclipse.xtext.ide.LexerIdeBindings.HIGHLIGHTING" +
					")).to(" + AntlrTokenDefProvider.class.getName() +".class)");
		} else {
			binder.addConfiguredBinding("HighlightingLexer",
					"binder.bind(" + Lexer.class.getName() + ".class)"+
					".annotatedWith(com.google.inject.name.Names.named(" +
					"org.eclipse.xtext.ui.LexerUIBindings.HIGHLIGHTING" +
					")).to(" + getLexerClassName(grammar, getNaming()) +".class)")
				   .addConfiguredBinding("HighlightingTokenDefProvider",
					"binder.bind(" + ITokenDefProvider.class.getName() + ".class)"+
					".annotatedWith(com.google.inject.name.Names.named(" +
					"org.eclipse.xtext.ui.LexerUIBindings.HIGHLIGHTING" +
					")).to(" + AntlrTokenDefProvider.class.getName() +".class)");
		}
		return binder.getBindings();
}
 
开发者ID:eclipse,项目名称:xtext-extras,代码行数:30,代码来源:XtextAntlrGeneratorFragment.java

示例3: bindITokenDefProvider

import org.eclipse.xtext.parser.antlr.AntlrTokenDefProvider; //导入依赖的package包/类
public Class<? extends ITokenDefProvider> bindITokenDefProvider() {
	return AntlrTokenDefProvider.class;
}
 
开发者ID:rehne93,项目名称:pokemon-tcgo-deck-generator,代码行数:4,代码来源:AbstractPkmntcgoRuntimeModule.java

示例4: configureHighlightingTokenDefProvider

import org.eclipse.xtext.parser.antlr.AntlrTokenDefProvider; //导入依赖的package包/类
public void configureHighlightingTokenDefProvider(Binder binder) {
	binder.bind(ITokenDefProvider.class)
		.annotatedWith(Names.named(LexerIdeBindings.HIGHLIGHTING))
		.to(AntlrTokenDefProvider.class);
}
 
开发者ID:rehne93,项目名称:pokemon-tcgo-deck-generator,代码行数:6,代码来源:AbstractPkmntcgoUiModule.java


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