See Process and ProcessBuilder classes.
Specifically, you would create a Process. Process.getOutputStream() gives an InputStream, from which you read what the process's output. You also need to read Process.getErrorStream() for any errors that the process reports.