The main part of this is the completion of our the Java-based evaluator with support for animations
To support animations in the evaluator, you need to complete the implementation of the start() and stop() methods in oop.eval.Evaluator. The start() method should start an animation by spawning a new Java thread, which steps through the current tree until there's nothing left to evaluate, i.e., until the root is not reducible any more. In more detail, the loop performs one step using the evaluator's stepper and then rests for DELAY milliseconds, with DELAY defaulting to 1000. The animator thread exits the loop under two conditions: (1) if the current tree is not reducible any more, and (2) if the stop() method has been invoked. Note that the thread must exist the loop almost immediately after a call to stop() and, if it is resting, should not just finish the resting period.
To ensure consistent naming, the animator thread must be implemented by a class called [url removed, login to view], which implements the [url removed, login to view] interface.
The most important part of this is to make sure that the animator and the Swing user interface interact in a thread-safe manner. In particular, make all updates to the user interface and to our tree view's data model with the Swing event dispatch thread. Furthermore, the communication from user interface to the animator must also be thread-safe.
Use any form of synchronization that meets these requirements. But also thrife for simplicity. Multi-threaded programming is hard enough, don't make it harder!
Make sure to correctly update the user interface if the user has pressed the stop button or the animator thread has finished animating. In particular, the stop button has to become the animate button again.
Also make sure that, if there is no current tree, clicking the animate button causes the text input field to be read and parsed.
Tasks also include:....
On each step, our evaluator currently updates our tree view from scratch. This works, but is also inefficient, I need it more efficient. It would be preferable to use treeStructureChanged() events to communicate model changes to the tree view. So change our evaluator, including the tree model adapter and the stepper, to incrementally update the tree. Please include a little with your code that describes how you got it to work right and efficiently.
Tasks also include:....
Our stepper does not work correctly for assignments. the problem is that instances of [url removed, login to view] have two meanings, depending on whether they appear as l-values or not. An l-value is a value appearing on the left-hand side of an assignment; it needs be treated differently from all other occurrences (as it should be in our evaluator). So, fix the stepper to correctly handle names as l-values. Your solution should not be longer than one line of code containing an if statement.
At the end of the project please provide the source code for any classes modified and for any new classes created.
6 freelancers are bidding on average $92 for this job
We will doing all that you want (and more...:-))). Quickly, Professional, Quality - our answer you and your organization. It means that with us ALWAYS is possible to agree. There are questions?
I am an experienced java programmer willing to make freelance as my career.I will certainly deliever the project on time and am looking for future collaboration.