• Post Reply Bookmark Topic Watch Topic
  • New Topic

How to parser a given String?  RSS feed

 
Diego Victor S. de Sousa
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi everyone,
I had propose an language to solve a problem.
The language is defined in a BNF grammar.
I want to translate my language to a Logical model.
Someone knows a best way to catch each string component an do a some operation with it?
 
Jesper de Jong
Java Cowboy
Sheriff
Posts: 16028
87
Android IntelliJ IDE Java Scala Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Welcome to the Ranch.

I'm not sure what exactly your question is. Do you want to write a parser for a custom language that you've designed? Maybe you can use ANTLR for this, a parser generator.
 
Diego Victor S. de Sousa
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The user must write a Query in my language and then for each language component i will create a component in a timed automaton of the UPPAAL tool (www.uppaal.org).
I see that ANTRL just create parsers to some specific target languages.
I want to interpret a language defined by me to a logical model of the UPPAAL tool.
Do you understand?
 
Jesper de Jong
Java Cowboy
Sheriff
Posts: 16028
87
Android IntelliJ IDE Java Scala Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You can use ANTLR to parse your own language. What you then do with the output of the parser is up to you. You could use it to create a logical model for the UPPAAL tool.
 
Diego Victor S. de Sousa
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I will try ANTRL.
I thought that would be not possible to translate a language to anything with ANTRL.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!