Skip to content

🔡 A lexical scanner (Jflex) and parser (CUP) for parsing JSON

Notifications You must be signed in to change notification settings

CaroloS/JSON_lexer_parser

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

JSON_lexer_parser

Overview
A JSON lexer and parser that will take input and check if input is valid JSON based on the official structural specifications (http://json.org/). The main files are:

Scanner.jflex: A lexical generator (scanner) in Jflex
Parser.cup: A syntax analyser (parser) in CUP

Requirements
Java
ant

Running
To run use the following commands:
$ ant clean
$ ant jar
$ java -jar jar/Compiler.jar
then enter your JSON (the output will be a list of the JSON values preceded by 'JSON parsed!'

Or specify input from a file, for example using the input.test file:
java -jar jar/Compiler.jar input.test

About

🔡 A lexical scanner (Jflex) and parser (CUP) for parsing JSON

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages