package net.tomp2p;

import java.io.File;
import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.io.IOException;

public class InteropUtil {

	private static final String TmpDir = "C:/Users/Christian/Desktop/interop/";
	
	public static byte[] readFromFile(String argument, int fileSize) throws IOException {
		
		String path = String.format("%s%s-in.txt", TmpDir, argument);
		
		FileInputStream fis = new FileInputStream(path);
		byte[] buffer = new byte[fileSize];
		try {
			fis.read(buffer);
		}
		finally {
			fis.close();
		}
		
		return buffer;
	}

	public static void writeToFile(String argument, byte[] bytes) throws IOException {
		
		String path = String.format("%s%s-out.txt", TmpDir, argument);
		
		File file = new File(path);
		FileOutputStream fos = new FileOutputStream(file);
		try {
			fos.write(bytes);
		}
		finally {
			fos.close();
		}
	}
}

@@ -158,16 +158,18 @@
 til %7B%0A%0A%09
+//
 private 
@@ -236,16 +236,77 @@
 erop/%22;%0A
+%09private static final String TmpDir = %22D:/Desktop/interop/%22;%0A
 %09%0A%09publi

add file locations