• Post Reply Bookmark Topic Watch Topic
  • New Topic

Overwriting files automatically  RSS feed

 
Michael Preston
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Overview: I am creating automated assignment marking system, in which the goal is: suppose there are 100 students' assignments in a directory and if I start my program it should check all of the assignment.java one by one and generate a report based on that.

Clearer explanation:
At the moment, I have got assignment.java of 1 student and my Testing.java (which creates an object of the class in assignment.java and generates a report based on the output of assignment.java). So, till now what I am able to achieve is: Inside the Test project (which contains Testing.java), I import assignment.java; run the Testing.java and generate the report. When it comes to second student, I remove previous assignment.java import new assignment2.java(second student); run the Testing.java, which uses the students program and generates the report.

What I want to achieve is, In my Testing.java instead of importing assignments one by one and marking them, I want to automate it. i.e. In my Testing.java, if I specify the path of the directory in which all assignments are placed, my system should automatically overwrite (import new assignment removing the older) assignment.java and generate a report based on that.

Any help would be greatly appreciated.

Thank you.
 
Joe Ess
Bartender
Posts: 9406
12
Linux Mac OS X Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Welcome to the JavaRanch. While we would love to help, we ask that you DoYourOwnHomework. Have a look at our FAQ, HowToAskQuestionsOnJavaRanch and come back with a very specific, code-based question (i.e. here's what I tried, what I want and what I got).
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!