Map<String, Object> properties = new HashMap<String, Object>();
properties.put("LD_LIBRARY_PATH", "/pica/sybase/lib");
properties.put("FILEMAP", "/pica/tolk/confdir/FILEMAP");
RemoteExec remoteExec = new RemoteExec();
remoteExec.setCommand(command);
remoteExec.setHost("merkur.d-nb.de");
remoteExec.setUser("tolk");
remoteExec.setPassword("hads%szl");
remoteExec.setEnvironmentProperties(properties);
StringWriter writer = new StringWriter();
Reader reader = new BufferedReader(new InputStreamReader(
new FileInputStream("test/input/02499250X.pp"),
new PicaCharset()));
// StringBuffer buffer = new StringBuffer();
// int i;
// while((i=reader.read())!=-1) {
// buffer.append((char)i);
// }
// buffer.append("\n");
// StringReader reader2 = new StringReader(buffer.toString());
remoteExec.remoteExec(reader, writer, new PicaCharset(), Charset
.forName("UTF-8"), null, null);
logger.info("output2: " + writer.toString());
}