The following project is considered appropriate for a graduation dissertation in Computer Science
Graduation project if the supervising professor is good in Java
An English Word Statistics in Java
The function may include:

1. To ask client to select a text file to open (FileDialog would be good to start with)
2. To read the opened file word by word so that a String array/linked list(or other structures such as Vector…) may store each word with its frequency (i.e. the time of appearance of a word on the file).
3. Create a GUI where a Textarea (JtextArea would be good) instance showing whole text and conresponding outcomes upon requests
4. Upon sorting request by client, all the words will be shown in the textarea in a descending/ ascending order, or in terms of appearing frequency
5. Upon search request, a client will be asked to submit a word to be searched. In return, in the text area the outcome will indicate whether the word is found or not. If it is found, the appearance frequency will be shown as well.
6. The result and other messages could be saved/stored in a new file upon request upon request.
7. May receive “quit” request from client so that the program terminates.
8. The GUI should thus have several JButtons better with ImageIcon for the sake of aesthetics for submitting different requests by the client

The dissertation may include brief introduction to the UNICODE, the capability of word processing in Java. Of course, the discussion may extend the words prosecced to other langues, such as Chinese, Korea, Japanese, Russain, and so on, if the professor is also interested in other languages.
Please provide comments and suggestion for such kind of a project.

Edited 6 Years Ago by tong1: n/a

It seems to me you have everything you need, except "teh codez", of course, but those you're going to have to make yourself.


Now that that comment is out of the way, what do you need help with here? What about those requirements do you not understand?

Thank you for your quick response. To make the project better or perfect is my intention. Yes we have to write code by ourselves. But you may provide more specification to this kind of a project please, which is what I am looking for. There are at least two threads discussing about the titles of a graduation project, but no any concrete outcome. My thread is a specific one.

Edited 6 Years Ago by tong1: n/a

Yes, okay, it seems you already have an idea, so work with it. What, exactly, are you asking? (although I would say that "FileDialog" is wrong, "JFileChooser" is better). I would also use two JTextAreas. One to show the original text (possibly with the "searched" word highlighted), and one to show the search results (although a JTextField would be enough for a single word search.

Edited 6 Years Ago by masijade: n/a

Thank you very much indeed for telling me the JFileChooser which I did not use before. I will study the JFileChooser via API. Your response is exactly I am looking for.
Could you please show me how to highlit a word in JTextArea? What method I should use?

Thank you for your information. I have tested on the web page. It works. Then I downloaded the code: TextFieldDemo.java and compiled it successfully. However, error messages appears when interpreting it by JVM:

Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
at java.io.Reader.<init>(Reader.java:61)
at java.io.InputStreamReader.<init>(InputStreamReader.java:55)
at word.TextFieldDemo.<init>(TextFieldDemo.java:73)
at word.TextFieldDemo$1.run(TextFieldDemo.java:234)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:597)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThre
ad.java:273)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.
java:183)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThre
ad.java:173)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:168)

at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:160)

at java.awt.EventDispatchThread.run(EventDispatchThread.java:121)

Looks like the reader can't find what it is it is suppossed to be reading. The real question, though, is what that has to do with anything. You don't plan on directly incorporating this demo code into your code, do you? If so, we're back to "teh codez".

This question has already been answered. Start a new discussion instead.