Class FileHandler


  • public class FileHandler
    extends java.util.logging.StreamHandler
    Logging file handler. Has autoflush capability.
    Author:
    K.Jaensch, klausj@phonetik.uni-muenchen.de
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected java.io.File file  
    • Constructor Summary

      Constructors 
      Constructor Description
      FileHandler​(java.io.File file)  
      FileHandler​(java.io.File file, boolean append)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.io.File getFile()  
      boolean isAutoflush()  
      void publish​(java.util.logging.LogRecord record)  
      void setAutoflush​(boolean autoflush)  
      • Methods inherited from class java.util.logging.Handler

        getEncoding, getErrorManager, getFilter, getFormatter, getLevel, reportError, setErrorManager, setFilter, setFormatter, setLevel
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from class java.util.logging.StreamHandler

        close, flush, isLoggable, setEncoding, setOutputStream
    • Field Detail

      • file

        protected java.io.File file
    • Constructor Detail

      • FileHandler

        public FileHandler​(java.io.File file,
                           boolean append)
                    throws java.lang.SecurityException,
                           java.io.FileNotFoundException
        Throws:
        java.lang.SecurityException
        java.io.FileNotFoundException
      • FileHandler

        public FileHandler​(java.io.File file)
                    throws java.lang.SecurityException,
                           java.io.FileNotFoundException
        Throws:
        java.lang.SecurityException
        java.io.FileNotFoundException
    • Method Detail

      • publish

        public void publish​(java.util.logging.LogRecord record)
        Overrides:
        publish in class java.util.logging.StreamHandler
      • getFile

        public java.io.File getFile()
        Returns:
        file
      • isAutoflush

        public boolean isAutoflush()
      • setAutoflush

        public void setAutoflush​(boolean autoflush)