Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

com.lutris.logging
Class ChannelWriter  view ChannelWriter download ChannelWriter.java

java.lang.Object
  extended byjava.io.Writer
      extended bycom.lutris.logging.ChannelWriter

class ChannelWriter
extends java.io.Writer

Internal Writer object that interfaces to the LogChannel. Can't be inner class of LogWriter, it must be passed to super constructor.


Field Summary
private  java.lang.StringBuffer buffer
           
private  LogChannel channel
           
private  boolean enabled
           
private  int level
           
 
Fields inherited from class java.io.Writer
lock
 
Constructor Summary
ChannelWriter(LogChannel logChannel, int logLevel)
          Construct a new writer.
 
Method Summary
 void close()
          Close is a no-op.
 void flush()
          Flush the buffer to the log file.
 void write(char[] cbuf, int off, int len)
          Main write method that transfers stuff to the buffer.
 
Methods inherited from class java.io.Writer
write, write, write, write
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

buffer

private java.lang.StringBuffer buffer

channel

private LogChannel channel

level

private int level

enabled

private boolean enabled
Constructor Detail

ChannelWriter

public ChannelWriter(LogChannel logChannel,
                     int logLevel)
Construct a new writer.

Method Detail

write

public void write(char[] cbuf,
                  int off,
                  int len)
Main write method that transfers stuff to the buffer.


flush

public void flush()
Flush the buffer to the log file.


close

public void close()
Close is a no-op.