/*
* 启动一个线程,读出InputStream 中的内容
*/
new Thread()
{
public void run()
{
BufferedReader reader = new BufferedReader(
new InputStreamReader(ldr.getInputStream()));
try
{
String line = reader.readLine();
if (logger.isDebugEnabled())
{
logger.debug("ORACLE SQLLoad Output Message: ");
}
while (line != null)
{
line = reader.readLine();
if (logger.isDebugEnabled())
{
logger.debug(line);
}
}
}
catch (IOException e)
{
logger.error("ORACLE SQLLoad get input stream failed.",
e);
}
finally
{
try
{
if (reader != null)
{
reader.close();
reader = null;
}
}
catch (IOException e)
{
logger.error(e.getMessage(), e);
}
}
}
}.start();
* 启动一个线程,读出InputStream 中的内容
*/
new Thread()
{
public void run()
{
BufferedReader reader = new BufferedReader(
new InputStreamReader(ldr.getInputStream()));
try
{
String line = reader.readLine();
if (logger.isDebugEnabled())
{
logger.debug("ORACLE SQLLoad Output Message: ");
}
while (line != null)
{
line = reader.readLine();
if (logger.isDebugEnabled())
{
logger.debug(line);
}
}
}
catch (IOException e)
{
logger.error("ORACLE SQLLoad get input stream failed.",
e);
}
finally
{
try
{
if (reader != null)
{
reader.close();
reader = null;
}
}
catch (IOException e)
{
logger.error(e.getMessage(), e);
}
}
}
}.start();