Advertisement
Guest User

Untitled

a guest
Nov 1st, 2014
149
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.00 KB | None | 0 0
  1. Compare correctness of iterator usage as well as performance of a given Java Collection: The collections and a test case will be provided by the TAs next week and the operations to be monitored for performance will also be suggested. TAs will give at least 3 choices (for collections), and one test case that uses all 3 collections will be provided. You may choose any one (and only one) of the collection, and then monitor it for performance and correctness. At the end comment on your observations. I suggest following steps.
  2. 1. The property to be considered for checking is FailSafeIter, which you have studies in the class.
  3. 2. Use JavaMOP to generate basic aspect. JavaMOP has a good website. Select version 2.3 (or the one suggested by the TAs) to generate an aspect for FailSafeIter. The aspect can be generated in two ways. One by downloading JavaMOP and running on your machine, or by generating aspect directly using their web tool version, and then by copying the generated aspect. Use "creation" tag for create event which will produce a simplified aspect.
  4. 2. Customize this aspect for your task. Choose any one collection for monitoring. The test case should have right type structure. However, develop your aspect by keeping in mind the situations that may arise due to type checking issues.
  5. 3. For the timing recording for the operations like add, remove etc. use System's nanoTime function unless you know something better.
  6. 4. Check the API documentation to understand the collection requirements. At the end, comment on whether your observations match the specification. If not, explain why you think were the differences, by providing a README file. The README file should also have the name of the Collection you used for monitoring.
  7. 5. You should report an error if you detect a property violation. If that crashes your program. You should comment the statement that crashed the program and provide the timing data at the end.
  8. 6. The data should be printed by adding an extra event at the end based on System's exit call.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement