Unix-tools replicating in JAVA