Skip to content

Commit b8f2c37

Browse files
committed
README
1 parent a97d550 commit b8f2c37

File tree

6 files changed

+47
-0
lines changed

6 files changed

+47
-0
lines changed

README.md

+47
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
# Python Lexer Analyzer with JFlex
2+
We developed a lexical analyzer for python using JFlex library.
3+
4+
## Prerequisites
5+
- [Java](https://www.java.com/pt_BR/)
6+
- [JFlex](https://www.jflex.de/)
7+
8+
## JFlex
9+
JFlex is a lexical analyzer generator (also known as scanner generator) for Java, written in Java.
10+
11+
### Develop Enviroment
12+
We're using the IntelliJ IDEA. But, you can do this on command line if you want.
13+
14+
### Getting Started
15+
Clone this rep by using
16+
> $ git clone https://github.com/chrismachado/Python-Lexer-Analyzer.git
17+
18+
### Running the Analyzer
19+
First of all, you need the Lexical class for it. So, you can get it with by running
20+
the *bin/LexerGenMain*, that should be the result:
21+
22+
![lexergen](images/lexergenmainterm.png)
23+
24+
After that, you need to run the GUI *view/InputPyFileScreen*, than choose your Python file.
25+
We have some examples in *files/*, you could use it or run your own code.
26+
27+
![input1](images/inputscreen1.png)
28+
29+
The Python Tokens are listed in to class *bin/PyTokens* as we show.
30+
31+
PS*: This list will be modified.
32+
33+
![pytokens](images/pytokens.png)
34+
35+
After you load your code, hit the Analyze button and you can see the Token, type and line of it. On bottom side, we show
36+
a table with the amount of each token. Like this.
37+
38+
![input1](images/input2.png)
39+
40+
### Authors
41+
- **Christiano Machado** @ [email protected]
42+
- **Anderson Sales** @ [email protected]
43+
44+
### Acknowledgments
45+
- **Professor Bruno Silva**
46+
47+

images/input2.png

39.8 KB
Loading

images/inputscreen1.png

17.4 KB
Loading

images/lexergenmainterm.png

10.1 KB
Loading

images/pytokens.png

9.84 KB
Loading

src/files/test3.py

Whitespace-only changes.

0 commit comments

Comments
 (0)