gpt4 book ai didi

linux - 我如何让 ANTLRWorks 工作?

转载 作者:IT王子 更新时间:2023-10-29 01:23:43 25 4
gpt4 key购买 nike

关注How do I install this damn thing? on www.antlr.org 我有 ANTLR 3.5 可以工作:

$ java -version    # I have Oracle`s Java JDK installed
java version "1.7.0_11"
Java(TM) SE Runtime Environment (build 1.7.0_11-b21)
Java HotSpot(TM) 64-Bit Server VM (build 23.6-b04, mixed mode)
$ ls
antlrworks-1.5.jar
$ export CLASSPATH=./antlrworks-1.5.jar:$CLASSPATH
$ java org.antlr.Tool -version
ANTLR Parser Generator Version 3.5

但根据ANTLRWorks: The ANTLR GUI Development Environment , ANTLRWorks 也应该包含在上面的 JAR 文件中。我该如何开始?


如果我键入 java a 并双击它,它首先将其完成为 java antlr.,这表明类路径上没有 antlrworks 包。我不知道是否应该有一个。如果我继续双击,我会得到:

antlr.ANTLRException                     antlr.CharStreamIOException              antlr.debug.ListenerBase                 antlr.debug.TraceListener                antlr.SemanticException
antlr.ANTLRHashString antlr.collections.AST antlr.debug.MessageEvent antlr.DefaultFileLineFormatter antlr.StringUtils
antlr.ANTLRStringBuffer antlr.collections.ASTEnumeration antlr.debug.MessageListener antlr.FileLineFormatter antlr.Token
antlr.ASTFactory antlr.collections.impl.ASTArray antlr.debug.ParserListener antlr.InputBuffer antlr.TokenBuffer
antlr.ASTNULLType antlr.collections.impl.ASTEnumerator antlr.debug.ParserMatchEvent antlr.LexerSharedInputState antlr.TokenQueue
antlr.ASTPair antlr.collections.impl.BitSet antlr.debug.ParserMatchListener antlr.LLkParser antlr.TokenStream
antlr.BaseAST antlr.collections.impl.IntRange antlr.debug.ParserTokenEvent antlr.MismatchedCharException antlr.TokenStreamException
antlr.ByteBuffer antlr.collections.impl.Vector antlr.debug.ParserTokenListener antlr.MismatchedTokenException antlr.TokenStreamIOException
antlr.CharBuffer antlr.collections.impl.VectorEnumerator antlr.debug.SemanticPredicateEvent antlr.NoViableAltException antlr.TokenStreamRecognitionException
antlr.CharFormatter antlr.CommonAST antlr.debug.SemanticPredicateListener antlr.NoViableAltForCharException antlr.TreeParser
antlr.CharQueue antlr.CommonToken antlr.debug.SyntacticPredicateEvent antlr.Parser antlr.TreeParserSharedInputState
antlr.CharScanner antlr.debug.Event antlr.debug.SyntacticPredicateListener antlr.ParserSharedInputState antlr.Utils
antlr.CharStreamException antlr.debug.GuessingEvent antlr.debug.TraceEvent antlr.RecognitionException

我通过访问 http://www.antlr.org/download.html 下载了 antlrworks-1.5.jar然后点击 Version 1.5 - for Windows, Linux and Mac OS X . JAR 的文件大小为 2684608 字节。

最佳答案

抱歉,如果这个答案太简单了

1) 转到 antlrworks站点并下载 antlrworks文件

2) cd 到您的下载文件夹,然后:java -jar antlrworks-1.5.jar

关于linux - 我如何让 ANTLRWorks 工作?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/14426034/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com