Reputation: 6805
I am a teacher and would like my students to have in front of them pretty printouts of the source code to 4 short Java files. I don't want to waste paper (or have them shuffling papers around), so I would like to have the four files on a single page. I don't want to print (from Eclipse) each to a separate PDF, then combine them 4-up, since that would make the text tiny. I tried concatenating the four files into a single .java file in Eclipse, but, despite reading this question, I found no way of suppressing the display of errors (namely defining multiple public classes in a single file).
Update: I don't just want to print the code as text. I would like it pretty-printed, i.e., with syntax highlighting.
Upvotes: 2
Views: 2746
Reputation: 1290
You could put the source together in one file, you have to make the necessary changes to make sure there is only one public class:
public class a {}
class B {}
Upvotes: 1