ua.gradsoft.termware.envs
Class SystemLogEnv

java.lang.Object
  extended by ua.gradsoft.termware.envs.SystemLogEnv
All Implemented Interfaces:
IEnv

public class SystemLogEnv
extends Object
implements IEnv

the same as SystemEnv, but in addition set input, output and log streams to appropriative files.


Constructor Summary
SystemLogEnv()
           
SystemLogEnv(Term t)
          t must be nil, or must look like
 
Method Summary
 void close()
          called before shutown of term system
 Reader getInput()
          get input
 PrintWriter getLog()
          get log stream
 PrintWriter getOutput()
          get standard output
 void setInput(Reader input)
          set input
 void setLog(PrintWriter log)
          set log stream
 void setOutput(PrintWriter output)
          set Output Stream.
 void show(TermWareException ex)
          show exception.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SystemLogEnv

public SystemLogEnv()

SystemLogEnv

public SystemLogEnv(Term t)
             throws IOException,
                    TermWareException
t must be nil, or must look like
 env(t_1,t_2,t_3)
 where 
   t_1 - string or atom 'system', which means standart input, or name of
         input file.
   t_2 - string or atom 'system', which means standart output, or name of
         output file.
   t_3 - string or atom 'system', which means standart error output, or 
         name of log file.

Throws:
IOException
TermWareException
Method Detail

getOutput

public PrintWriter getOutput()
get standard output

Specified by:
getOutput in interface IEnv

setOutput

public void setOutput(PrintWriter output)
set Output Stream.


getInput

public Reader getInput()
get input

Specified by:
getInput in interface IEnv

setInput

public void setInput(Reader input)
              throws IOException
set input

Throws:
IOException

getLog

public PrintWriter getLog()
get log stream

Specified by:
getLog in interface IEnv

setLog

public void setLog(PrintWriter log)
set log stream


show

public void show(TermWareException ex)
show exception.

Specified by:
show in interface IEnv

close

public void close()
Description copied from interface: IEnv
called before shutown of term system

Specified by:
close in interface IEnv